.gitea/workflows/buildah_test.yml aktualisiert
Buildah Rootless Test / test-build (push) Failing after 4s

next try
This commit is contained in:
2026-06-12 16:56:28 +00:00
parent 936597a27f
commit 1099fa3c94
+8 -18
View File
@@ -4,29 +4,19 @@ on: [push]
jobs: jobs:
test-build: test-build:
runs-on: ubuntu-latest runs-on: ubuntu-latest
# HIER: Kein globaler Container-Block mehr!
steps: steps:
# 1. Funktioniert jetzt wieder, da Node.js auf dem Runner-Host vorhanden ist - name: Image mit Buildah über Stdin bauen
- name: Code auschecken
uses: actions/checkout@v3
# 2. Erstellt die Testdatei im Workspace
- name: Test-Dockerfile erstellen
run: | run: |
echo "FROM alpine:latest" > Containerfile # Wir übergeben das Containerfile direkt als Here-Doc (<<-EOF) an den Container
echo "RUN echo 'Hello from rootless Buildah via Docker-Run!' > /hello.txt" >> Containerfile docker run -i --rm \
echo "CMD cat /hello.txt" >> Containerfile
# 3. Führt Buildah in einer maßgeschneiderten Sandbox aus
- name: Image mit Buildah bauen
run: |
docker run --rm \
-v ${{ github.workspace }}:/workspace \
-w /workspace \
--security-opt seccomp=unconfined \ --security-opt seccomp=unconfined \
--security-opt label=disable \ --security-opt label=disable \
quay.io/buildah/stable:latest \ quay.io/buildah/stable:latest \
buildah --storage-driver=vfs --isolation=chroot bud \ buildah --storage-driver=vfs --isolation=chroot bud \
-t lokales-test-image:latest \ -t lokales-test-image:latest \
-f Containerfile . -f - . <<-EOF
FROM alpine:latest
RUN echo 'Hello from rootless Buildah via Stdin!' > /hello.txt
CMD cat /hello.txt
EOF