name: Build & Push Docker Image to Registry on: release: types: [published] jobs: build: runs-on: laravel-runner-php84 steps: - name: Checkout code uses: actions/checkout@v4 - name: Install PHP dependencies run: composer install --no-interaction --prefer-dist --optimize-autoloader - name: Install JS dependencies and build assets run: | npm ci npm run build - name: Remove docs folder run: rm -rf docs - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 - name: Log in to Gitea Registry uses: docker/login-action@v3 with: registry: gitgud.foo username: docker_registry_pusher password: ${{ secrets.DOCKER_USER_PASSWORD }} - name: Build and push Docker image uses: docker/build-push-action@v5 with: context: ${{ github.workspace }} file: ${{ github.workspace }}/Dockerfile push: true tags: | gitgud.foo/thegrind/authentikate:latest gitgud.foo/thegrind/authentikate:${{ github.event.release.tag_name }}