All checks were successful
Build and push image / build (push) Successful in 1m24s
- Fix CI registry login (unauthorized): use dedicated REGISTRY_TOKEN secret instead of GITHUB_TOKEN, fail fast with a clear error if it's unset. - Pause ticket work-timer while a ticket is closed (won't auto-start on open or manual resume; stops on close via status change, quick action, API, or merge). - Reject empty/blank login submissions client- and server-side instead of passing them straight to the auth provider. - Closing a ticket now sends only the "ticket closed" notification instead of also sending a duplicate "status changed" one. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
50 lines
1.6 KiB
YAML
50 lines
1.6 KiB
YAML
name: Build and push image
|
|
|
|
# The app image only provides PHP/Apache/extensions — application code is bind-
|
|
# mounted from ./src at deploy time (see compose.yaml), so this only needs to
|
|
# run when the image definition itself changes, not on every app code change.
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
paths:
|
|
- Dockerfile
|
|
- .gitea/workflows/build.yml
|
|
|
|
permissions:
|
|
contents: read
|
|
packages: write
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v3
|
|
|
|
- name: Verify registry credentials are configured
|
|
run: |
|
|
if [ -z "${{ secrets.REGISTRY_TOKEN }}" ]; then
|
|
echo "::error::Secret REGISTRY_TOKEN is not set, so login to gitea.kzbikowski.pl would fail. Create a Gitea access token with 'write:package' (and 'read:package') scope — user Settings > Applications > Generate New Token — then add it as an Actions secret named REGISTRY_TOKEN under this repo's Settings > Actions > Secrets. Aborting before attempting login." >&2
|
|
exit 1
|
|
fi
|
|
|
|
- name: Log in to Gitea container registry
|
|
uses: docker/login-action@v3
|
|
with:
|
|
registry: gitea.kzbikowski.pl
|
|
username: ${{ github.actor }}
|
|
password: ${{ secrets.REGISTRY_TOKEN }}
|
|
|
|
- name: Build and push
|
|
uses: docker/build-push-action@v6
|
|
with:
|
|
context: .
|
|
file: ./Dockerfile
|
|
push: true
|
|
tags: |
|
|
gitea.kzbikowski.pl/kzbkowski/servicedesk:latest
|
|
gitea.kzbikowski.pl/kzbkowski/servicedesk:${{ github.sha }}
|