From b5877f36f591d47517ca9f269ce048db209b07ad Mon Sep 17 00:00:00 2001 From: Taqi Tahmid Date: Sat, 17 May 2025 22:04:52 +0300 Subject: [PATCH] fix --- .gitea/workflows/build.yaml | 33 ++++++++++++++++++++++----------- 1 file changed, 22 insertions(+), 11 deletions(-) diff --git a/.gitea/workflows/build.yaml b/.gitea/workflows/build.yaml index 62cafef..1e7ceda 100644 --- a/.gitea/workflows/build.yaml +++ b/.gitea/workflows/build.yaml @@ -28,6 +28,7 @@ jobs: build-and-release-image: runs-on: ubuntu-latest + container: catthehacker/ubuntu:act-latest needs: build-portfolio-website if: success() steps: @@ -36,15 +37,25 @@ jobs: with: fetch-depth: 0 # all history for all branches and tags - - name: Build and push Docker image - env: - REGISTRY: ${{ secrets.DOCKER_REGISTRY }} - USERNAME: ${{ secrets.DOCKER_USERNAME }} - PASSWORD: ${{ secrets.DOCKER_PASSWORD }} + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 with: - image: quay.io/podman/stable - options: --volumes-from=${{ env.JOB_CONTAINER_NAME }} - run: | - podman build -t "${REGISTRY}/my-portfolio:latest" . - podman login -u "${USERNAME}" -p "${PASSWORD}" "${REGISTRY}" - podman push "${REGISTRY}/my-portfolio:latest" + driver: kubernetes + driver-opts: | + namespace=act-runner + qemu.install=true + + - name: Login to Docker registry + uses: docker/login-action@v3 + with: + registry: ${{ secrets.DOCKER_REGISTRY }} + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + + - name: Build Docker image + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile + push: true + tags: ${{ secrets.DOCKER_REGISTRY }}/my-portfolio:latest