asd
All checks were successful
Build and Publish Images / build-and-push (push) Successful in 1m24s

This commit is contained in:
arrelin
2026-03-06 15:39:16 +03:00
parent 5051b8e9de
commit 6f43059b5f
2 changed files with 85 additions and 0 deletions

36
.github/workflows/docker-publish.yml vendored Normal file
View File

@@ -0,0 +1,36 @@
name: Build and Publish Images
on:
push:
branches: [ main, master ]
workflow_dispatch:
jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Login to Gitea Registry
run: echo "${{ secrets.REGISTRY_PASSWORD }}" | docker login 192.168.31.100:3847 -u ${{ secrets.REGISTRY_USER }} --password-stdin
- name: Build and push backend image
run: |
docker build -t 192.168.31.100:3847/arrelin/wedding-backend:latest -t 192.168.31.100:3847/arrelin/wedding-backend:${{ gitea.sha }} ./backend
docker push 192.168.31.100:3847/arrelin/wedding-backend:latest
docker push 192.168.31.100:3847/arrelin/wedding-backend:${{ gitea.sha }}
- name: Build and push frontend image
run: |
docker build -t 192.168.31.100:3847/arrelin/wedding-frontend:latest -t 192.168.31.100:3847/arrelin/wedding-frontend:${{ gitea.sha }} ./frontend
docker push 192.168.31.100:3847/arrelin/wedding-frontend:latest
docker push 192.168.31.100:3847/arrelin/wedding-frontend:${{ gitea.sha }}
- name: Logout
run: docker logout 192.168.31.100:3847
# - name: Trigger Coolify redeploy
# run: |
# curl -s -H "Authorization: Bearer ${{ secrets.COOLIFY_TOKEN }}" \
# "http://192.168.31.100:8000/api/v1/deploy?uuid=ВСТАВЬ_UUID_СЮДА&force=true"