8 Commits

Author SHA1 Message Date
6e5bf040dc fix: v0.1.2
Some checks failed
/ build and run u-api (push) Failing after 2s
/ clean (push) Successful in 0s
2025-05-09 23:06:21 +08:00
1a8827a67a fix: v0.1.2
Some checks failed
/ build and run u-api (push) Failing after 2s
/ clean (push) Successful in 0s
2025-05-09 23:03:46 +08:00
761b1d3b27 fix: v0.1.2
Some checks failed
/ build and run u-api (push) Failing after 3s
/ clean (push) Successful in 0s
2025-05-09 22:52:32 +08:00
fb66b2c359 fix: v0.1.2
Some checks failed
/ build and run u-api (push) Failing after 3s
/ clean (push) Successful in 0s
2025-05-09 22:45:32 +08:00
ad1b096a3b fix: v0.1.2
Some checks failed
/ build and run u-api (push) Failing after 3s
/ clean (push) Successful in 0s
2025-05-09 22:44:31 +08:00
2d992e36ec fix: v0.1.2
Some checks failed
/ build and run u-api (push) Failing after 2s
/ clean (push) Successful in 0s
2025-05-09 22:11:54 +08:00
91f3da635d fix: v0.1.2
Some checks failed
/ build and run u-api (push) Failing after 2s
/ clean (push) Successful in 0s
2025-05-09 22:10:18 +08:00
93c4339039 init: 0.1.2
Some checks failed
/ build and run u-api (push) Failing after 8s
/ clean (push) Successful in 0s
feat: login page && auth required
todo: file dir cleanup
2025-05-09 17:49:12 +08:00
2 changed files with 13 additions and 25 deletions

View File

@ -5,7 +5,7 @@ on:
- 'v*'
jobs:
build ushare:
build and run u-api:
runs-on: tencent-sg
steps:
- name: prepare enviroment
@ -17,6 +17,9 @@ jobs:
- name: print operator
run: whoami
- name: print work dir and files
run: pwd & ls -alsh .
- name: print tag name
run: echo "Tag name = ${{ gitea.ref_name }}"
@ -26,29 +29,14 @@ jobs:
${{ secrets.DOCKER_CONFIG }}
EOF
- name: print work dir and files
run: pwd & ls -alsh .
- name: build image by docker build
run: docker build -t gitea.loveuer.com/loveuer/build/ushare:${{ gitea.ref_name }} .
- name: login repository
run: echo ${{ secrets.DOCKER_REPOSITORY_PASSWORD }} | docker login --username loveuer --password-stdin gitea.loveuer.com/loveuer
- name: push image to repository
run: docker push gitea.loveuer.com/loveuer/build/ushare:${{ gitea.ref_name }}
# - name: build by kaniko in docker
# run: |
# docker run --rm -v $(pwd):/workspace \
# -v $(pwd)/.docker.config.json:/kaniko/.docker/config.json:ro \
# alpine:latest \
# ls -alsh /workspace
# gcr.io/kaniko-project/executor:latest \
# --dockerfile=/workspace/Dockerfile \
# --context=/workspace \
# --destination=gitea.loveuer.com/loveuer/build/u-api:${{ gitea.ref_name }} \
# --single-snapshot
- name: build by kaniko in docker
run: |
docker run --rm -v $(pwd):/workspace \
-v $(pwd)/.docker.config.json:/kaniko/.docker/config.json:ro \
gcr.io/kaniko-project/executor:latest \
'-f /workspace/Dockerfile' \
'-d "gitea.loveuer.com/loveuer/build/ushare:${{ gitea.ref_name }}"' \
'--single-snapshot'
clean:
if: always()

View File

@ -32,4 +32,4 @@ COPY deployment/nginx.conf /etc/nginx/conf.d
EXPOSE 80
# 启动服务
CMD ["sh", "-c", "nginx -g 'daemon off;' & exec ushare"]
CMD sh -c "ushare & nginx -g 'daemon off;'"