File tree Expand file tree Collapse file tree 2 files changed +40
-1
lines changed
Expand file tree Collapse file tree 2 files changed +40
-1
lines changed Original file line number Diff line number Diff line change 1+ name : dockerfile--siteproxy-构建和提交docker
2+
3+ on :
4+ push :
5+ branches : [main]
6+ paths :
7+ - " dockerfile/**"
8+ - " .github/workflows/dockerfile--siteproxy.yml"
9+ - " !**.md"
10+
11+ jobs :
12+
13+ # 并发构建
14+ setup-build-publish-v3 :
15+ runs-on : ubuntu-latest
16+ name : 构建和推送docker镜像v3
17+ steps :
18+
19+ - name : 更新代码
20+ # 使用action库 actions/checkout获取源码
21+ uses : actions/checkout@v3
22+
23+
24+ -
25+ name : 登录 Docker Hub
26+ uses : docker/login-action@v2
27+ with :
28+ username : adockero
29+ password : ${{ secrets.PASSWORD }}
30+
31+ - name : tcp-proxy-base64 Build and push
32+ run : |
33+ chmod +x dockerfile/build.sh
34+ ./dockerfile/build.sh "https://github.com/netptop/siteproxy" "adockero/siteproxy"
35+
Original file line number Diff line number Diff line change @@ -10,7 +10,11 @@ echo "Dockerfile path: $DOCKERFILE_PATH"
1010echo " Image name: $IMAGE_NAME "
1111
1212# Clone repository
13- git clone https://github.com/aogg/$GITHUB_NAME project
13+ if [[ " $GITHUB_NAME " == http://* ]] || [[ " $GITHUB_NAME " == https://* ]]; then
14+ git clone $GITHUB_NAME project
15+ else
16+ git clone https://github.com/aogg/$GITHUB_NAME project
17+ fi
1418cd project
1519
1620# Build image
You can’t perform that action at this time.
0 commit comments