diff --git a/.forgejo/workflows/build-on-commit.yml b/.forgejo/workflows/build-on-commit.yml index a4094f5..3546e18 100644 --- a/.forgejo/workflows/build-on-commit.yml +++ b/.forgejo/workflows/build-on-commit.yml @@ -23,6 +23,13 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 + with: + driver: docker-container + driver-opts: | + network=host + endpoint: tcp://docker:2376 + install: true + config: /certs/client/config.json - name: Login to OCI registry run: | @@ -30,7 +37,6 @@ jobs: - name: Build and push multi-arch Docker images run: | - docker buildx create --use docker buildx build \ --platform linux/amd64,linux/arm64 \ --tag $REPO_HOST/$REPO_PATH:${{ github.sha }} \ @@ -38,5 +44,7 @@ jobs: --push \ . - - name: Remove builder (optional cleanup) - run: docker buildx rm + - name: Cleanup + run: | + docker buildx prune -f + docker logout $REPO_HOST \ No newline at end of file