Alt build method
All checks were successful
Publish Builder Image / build-and-push (push) Successful in 3m8s

This commit is contained in:
2025-12-01 21:06:13 +01:00
parent 53a77df7a6
commit 9dee58b6ab
2 changed files with 48 additions and 1 deletions

View File

@ -0,0 +1,46 @@
name: Publish Builder Image
on:
push:
jobs:
build-and-push:
runs-on: ubuntu-latest
# 1. Define the container for the ENTIRE job
container:
image: quay.io/buildah/stable
# 2. IMPORTANT: We must pass the privileged flag here for Buildah to work
options: --privileged
steps:
- name: Checkout
uses: actions/checkout@v3
# 3. Now you can use the standard 'run' keyword!
- name: Build and Push
env:
USERNAME: ${{ gitea.actor }}
PASSWORD: ${{ secrets.USER_PACKAGE_PASSWORD }}
REGISTRY: gitea.212.63.210.91.nip.io
IMAGE: ${{ gitea.repository_owner }}/godot-builder
TAG: ${{ gitea.sha }}
run: |
# Now comments are safe because 'run' uses a script file, not a one-liner.
# 1. Login to the registry
# We use --tls-verify=false for your internal Traefik certs
buildah login -u $USERNAME -p $PASSWORD --tls-verify=false --storage-driver=vfs $REGISTRY
# 2. Build the image
# Using the 'vfs' driver is slower but more stable for nested containers
buildah build \
--tls-verify=false \
--storage-driver=vfs \
-f Dockerfile \
-t $REGISTRY/$IMAGE:$TAG \
-t $REGISTRY/$IMAGE:latest \
.
# 3. Push the tags
buildah push --tls-verify=false --storage-driver=vfs $REGISTRY/$IMAGE:$TAG
buildah push --tls-verify=false --storage-driver=vfs $REGISTRY/$IMAGE:latest

View File

@ -29,3 +29,4 @@ jobs:
buildah push --tls-verify=false --storage-driver=vfs $REGISTRY/$IMAGE:latest
"