Some checks failed
Build and Push Docker Image / build-and-push (push) Failing after 17s
Remove DIND complexity in favor of standard Docker socket mounting: - Use actions/checkout@v4 instead of manual git clone - Remove DOCKER_HOST configuration - Remove Docker installation steps - Rely on runner's Docker daemon access This requires runner to be configured with Docker socket mount. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
32 lines
1,012 B
YAML
32 lines
1,012 B
YAML
name: Build and Push Docker Image
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
build-and-push:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Log in to Forgejo Container Registry
|
|
run: echo "${{ secrets.GITEA_TOKEN }}" | docker login forgejo.sivic.me -u ${{ github.actor }} --password-stdin
|
|
|
|
- name: Build and push Docker images
|
|
run: |
|
|
docker build \
|
|
-t forgejo.sivic.me/${{ github.repository }}:latest \
|
|
-t forgejo.sivic.me/${{ github.repository }}:${{ github.sha }} \
|
|
.
|
|
docker push forgejo.sivic.me/${{ github.repository }}:latest
|
|
docker push forgejo.sivic.me/${{ github.repository }}:${{ github.sha }}
|
|
|
|
- name: Summary
|
|
run: |
|
|
echo "✅ Successfully built and pushed:"
|
|
echo " - forgejo.sivic.me/${{ github.repository }}:latest"
|
|
echo " - forgejo.sivic.me/${{ github.repository }}:${{ github.sha }}"
|