From 5221a58b733ea36741cfaab31b1b2d76455357f3 Mon Sep 17 00:00:00 2001 From: Tobias Brunner Date: Tue, 14 Nov 2023 21:49:39 +0100 Subject: [PATCH] another approach --- .gitea/workflows/build-push.yaml | 32 ++++++++++++++------------------ 1 file changed, 14 insertions(+), 18 deletions(-) diff --git a/.gitea/workflows/build-push.yaml b/.gitea/workflows/build-push.yaml index fe87999..890c89c 100644 --- a/.gitea/workflows/build-push.yaml +++ b/.gitea/workflows/build-push.yaml @@ -8,29 +8,25 @@ jobs: container: catthehacker/ubuntu:act-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: Install Tools - run: sudo apt-get -y update && sudo apt-get -y install buildah + run: sudo apt-get -y update && sudo apt-get -y install docker - - name: Build Image - id: build-image - uses: redhat-actions/buildah-build@v2 - with: - image: ioteer - tags: latest ${{ github.sha }} - containerfiles: | - ./Dockerfile + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 - - name: Push To git.tbrnt.ch - id: push-to-gitea - uses: redhat-actions/push-to-registry@v2 + - name: Login to Docker Registry + uses: docker/login-action@v3 with: - image: ${{ steps.build-image.outputs.image }} - tags: ${{ steps.build-image.outputs.tags }} - registry: git.tbrnt.ch/tobru + registry: git.tbrnt.ch username: ${{ secrets.REGISTRY_USERNAME }} password: ${{ secrets.REGISTRY_TOKEN }} - - name: Print image url - run: echo "Image pushed to ${{ steps.push-to-gitea.outputs.registry-paths }}" \ No newline at end of file + - name: Build and push + uses: docker/build-push-action@v5 + with: + context: . + push: true + tags: | + git.tbrnt.ch/tobru/ioteer:latest \ No newline at end of file