From 796bfb0ab5644e6753efcf44090b0f3b46523bc3 Mon Sep 17 00:00:00 2001 From: Mindfang Date: Mon, 22 Jan 2024 19:24:31 -0600 Subject: [PATCH] Playing with buildx --- .gitea/workflows/commit.yaml | 46 ++++++++++++++++++++---------------- 1 file changed, 26 insertions(+), 20 deletions(-) diff --git a/.gitea/workflows/commit.yaml b/.gitea/workflows/commit.yaml index 247a867..413d68b 100644 --- a/.gitea/workflows/commit.yaml +++ b/.gitea/workflows/commit.yaml @@ -12,7 +12,7 @@ env: jobs: build-and-push-image: - runs-on: self-hosted + runs-on: ubuntu-latest permissions: contents: read @@ -25,27 +25,33 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 - - name: Log in to registry - uses: docker/login-action@v3 - with: - registry: ${{ env.REGISTRY }} - username: ${{ gitea.actor }} - password: ${{ secrets.AUTH_TOKEN }} + - name: Build image + run: | + buildx build . + # - name: Log in to registry + # uses: docker/login-action@v3 + # with: + # registry: ${{ env.REGISTRY }} + # username: ${{ gitea.actor }} + # password: ${{ secrets.AUTH_TOKEN }} - - name: Extract metadata for registry - id: meta - uses: docker/metadata-action@v5 - with: - images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} - tags: type=raw,value=latest,enable={{is_default_branch}} + # - name: Extract metadata for registry + # id: meta + # uses: docker/metadata-action@v5 + # with: + # images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} + # tags: type=raw,value=latest,enable={{is_default_branch}} - - name: Build and push Docker image - uses: docker/build-push-action@v5 - with: - context: . - push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} + # - name: Build and push Docker image + # uses: docker/build-push-action@v5 + # with: + # context: . + # push: true + # tags: ${{ steps.meta.outputs.tags }} + # labels: ${{ steps.meta.outputs.labels }}