Files
ai-stack-deployer/.gitea/workflows/docker-publish.yaml
Oussama Douhou 254b7710d7 fix: add docker-compose files to workflow trigger paths
Problem: Commit dd063d5 modified docker-compose*.yml files but did NOT
trigger Gitea Actions build because docker-compose files were not in the
workflow's paths trigger list.

Evidence:
- git show --stat dd063d5 shows only docker-compose*.yml and docs/ changed
- .gitea/workflows/docker-publish.yaml paths did not include docker-compose*.yml
- Gitea Actions did not run after push (verified by user)

Solution:
Added 'docker-compose*.yml' to workflow paths trigger list.

Justification:
Docker-compose files are deployment configuration that should trigger
image rebuilds when changed. This ensures Dokploy applications always
pull images with the latest docker-compose configurations.

Testing:
This commit will trigger a build because it modifies .gitea/workflows/**
(which is in the paths list). Future docker-compose changes will also trigger.
2026-01-13 13:24:36 +01:00

62 lines
1.5 KiB
YAML

name: Build and Push Docker Image
on:
push:
branches:
- dev
- staging
- main
paths:
- 'src/**'
- 'client/**'
- 'Dockerfile'
- 'docker-compose*.yml'
- 'package.json'
- '.gitea/workflows/**'
workflow_dispatch:
env:
REGISTRY: git.app.flexinit.nl
IMAGE_NAME: oussamadouhou/ai-stack-deployer
jobs:
build-and-push:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Gitea Container Registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: oussamadouhou
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Extract metadata
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/main' }}
type=raw,value=dev,enable=${{ github.ref == 'refs/heads/dev' }}
type=raw,value=staging,enable=${{ github.ref == 'refs/heads/staging' }}
type=sha,prefix={{branch}}-
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}