puffin-app/.gitea/workflows/build-deploy.yml
Matt 6d53650352
Some checks failed
Build and Push Docker Image / build (push) Failing after 4s
Switch to Docker-based workflow with CLI commands
Replace Kaniko approach with direct Docker CLI commands.
The Gitea runner mounts Docker socket, making Docker available
in ubuntu-latest environment.

Key changes:
- Remove container specification (Kaniko lacks shell utilities)
- Use docker login with password-stdin for authentication
- Build with docker build using multiple -t tags
- Push both latest and commit SHA tags
- Works with Docker-based Gitea runners

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-29 13:53:34 +01:00

34 lines
901 B
YAML

name: Build and Push Docker Image
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Log in to Gitea Container Registry
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | docker login code.puffinoffset.com -u ${{ github.actor }} --password-stdin
- name: Build Docker image
run: |
docker build -t code.puffinoffset.com/matt/puffin-app:latest \
-t code.puffinoffset.com/matt/puffin-app:main-${{ github.sha }} \
.
- name: Push Docker images
run: |
docker push code.puffinoffset.com/matt/puffin-app:latest
docker push code.puffinoffset.com/matt/puffin-app:main-${{ github.sha }}
- name: Show image info
run: |
docker images | grep puffin-app