fix: simplify CI/CD and Dockerfile
Build and Deploy / build (push) Failing after 52s
Build and Deploy / deploy (push) Has been skipped

- Use github.actor instead of gitea.actor
- Add act-latest container for Gitea Actions
- Simplify Dockerfile to use alpine
- Remove CGO dependencies
- Fix frontend build path
This commit is contained in:
2026-07-16 10:33:23 +00:00
parent a79e8fb853
commit 8258160f95
2 changed files with 17 additions and 47 deletions
+12 -23
View File
@@ -10,49 +10,39 @@ on:
jobs:
build:
runs-on: ubuntu-latest
container:
image: catthehacker/ubuntu:act-latest
steps:
- uses: actions/checkout@v4
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
- name: Install frontend dependencies
working-directory: ./web
run: npm install
- name: Build frontend
working-directory: ./web
run: npm run build
run: |
npm install
npm run build
- name: Set up Docker Buildx
- name: Setup Docker
uses: docker/setup-buildx-action@v3
- name: Login to Gitea Registry
- name: Login to Registry
uses: docker/login-action@v3
with:
registry: git.viaeon.com
username: ${{ gitea.actor }}
username: ${{ github.actor }}
password: ${{ secrets.TOKEN }}
- name: Extract metadata
id: meta
uses: docker/metadata-action@v5
with:
images: git.viaeon.com/admin/anticaptcha
tags: |
type=ref,event=branch
type=semver,pattern={{version}}
type=sha
- name: Build and push
uses: docker/build-push-action@v5
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
tags: git.viaeon.com/admin/anticaptcha:latest
deploy:
runs-on: ubuntu-latest
@@ -68,5 +58,4 @@ jobs:
script: |
cd /opt/anticaptcha
docker-compose pull
docker-compose up -d
docker image prune -f
docker-compose up -d