Flask app init
Build, push image, and notify Watchtower / build-image (push) Failing after 2m41s
Build, push image, and notify Watchtower / notify (push) Has been skipped

This commit is contained in:
2026-07-16 17:07:02 +02:00
parent 5c9da1ab78
commit d7889a7bbc
5 changed files with 153 additions and 2 deletions
+39
View File
@@ -0,0 +1,39 @@
name: Build, push image, and notify Watchtower
on:
push:
branches:
- main # Only triggers the build on the main branch
jobs:
build-image:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Login to Gitea Container Registry
uses: docker/login-action@v3
with:
registry: git.matthiasg.dev
username: ninluc
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Cache Docker layers
uses: actions/cache@v4
with:
path: /tmp/.buildx-cache
key: buildx-cache-${{ github.sha }}
restore-keys: |
buildx-cache-
- name: Build and push Docker image
run: |
docker build -t git.matthiasg.dev/ninluc/smartwave-api:latest .
docker push git.matthiasg.dev/ninluc/smartwave-api:latest
notify:
needs: build-image
runs-on: ubuntu-latest
steps:
- name: Notify Watchtower
run: "curl -i -X POST -H \"Authorization: Bearer ${{ secrets.WATCHTOWER_TOKEN }}\" https://watchtower.beermaker.matthiasg.dev/v1/update"