From f1f125705183a36ec60b1a72f56725bbf94e8cb6 Mon Sep 17 00:00:00 2001 From: Alex Wellnitz Date: Mon, 17 Mar 2025 16:31:01 +0100 Subject: [PATCH] feat: add push docker image func --- .gitea/workflows/build-container-image.yaml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/build-container-image.yaml b/.gitea/workflows/build-container-image.yaml index b7fa21f..f990b16 100644 --- a/.gitea/workflows/build-container-image.yaml +++ b/.gitea/workflows/build-container-image.yaml @@ -11,7 +11,7 @@ jobs: uses: docker/metadata-action@v5 with: images: | - gitea.example.com/xyz/alpine + git.dev-null.rocks/alexohneander/alexohneander-zola tags: | type=schedule,pattern={{date 'YYYYMMDDHHMM'}} type=semver,pattern={{version}} @@ -40,11 +40,22 @@ jobs: DOCKER_TLS_VERIFY: 1 DOCKER_CERT_PATH: "/certs/client" + - name: Login to Gitea + uses: docker/login-action@v3 + with: + registry: git.dev-null.rocks + username: ${{ gitea.actor }} + password: ${{ secrets.GA_TOKEN }} + - name: Build and push the image uses: docker/build-push-action@v5 with: file: Dockerfile platforms: linux/amd64 + push: true + context: containers/test + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} env: DOCKER_HOST: "tcp://docker:2376/" DOCKER_TLS_CERTDIR: "/certs"