diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index d83967f..862e4f8 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -23,41 +23,52 @@ jobs: id: tag run: echo "TAG=${GITHUB_SHA::8}" >> $GITHUB_OUTPUT - - name: Build and push bot image - uses: aevea/action-kaniko@master + - name: Log in to registry + uses: docker/login-action@v3 with: registry: git.chemavx.xyz username: chemavx password: ${{ secrets.CI_TOKEN }} - image: chemavx/polymarket-bot - tag: ${{ steps.tag.outputs.TAG }} - path: . - build_file: Dockerfile - extra_args: --insecure --skip-tls-verify --registry-mirror=mirror.gcr.io + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + with: + driver: docker-container + driver-opts: network=host + buildkitd-config-inline: | + [registry."git.chemavx.xyz"] + http = true + insecure = true + + - name: Build and push bot image + uses: docker/build-push-action@v3 + with: + context: . + file: Dockerfile + push: true + tags: git.chemavx.xyz/chemavx/polymarket-bot:${{ steps.tag.outputs.TAG }} + cache-from: type=registry,ref=git.chemavx.xyz/chemavx/polymarket-bot:buildcache + cache-to: type=registry,ref=git.chemavx.xyz/chemavx/polymarket-bot:buildcache,mode=max - name: Build and push API image - uses: aevea/action-kaniko@master + uses: docker/build-push-action@v3 with: - registry: git.chemavx.xyz - username: chemavx - password: ${{ secrets.CI_TOKEN }} - image: chemavx/polymarket-bot-api - tag: ${{ steps.tag.outputs.TAG }} - path: . - build_file: Dockerfile.api - extra_args: --insecure --skip-tls-verify --registry-mirror=mirror.gcr.io + context: . + file: Dockerfile.api + push: true + tags: git.chemavx.xyz/chemavx/polymarket-bot-api:${{ steps.tag.outputs.TAG }} + cache-from: type=registry,ref=git.chemavx.xyz/chemavx/polymarket-bot-api:buildcache + cache-to: type=registry,ref=git.chemavx.xyz/chemavx/polymarket-bot-api:buildcache,mode=max - name: Build and push dashboard image - uses: aevea/action-kaniko@master + uses: docker/build-push-action@v3 with: - registry: git.chemavx.xyz - username: chemavx - password: ${{ secrets.CI_TOKEN }} - image: chemavx/polymarket-bot-dashboard - tag: ${{ steps.tag.outputs.TAG }} - path: dashboard - build_file: Dockerfile - extra_args: --insecure --skip-tls-verify --registry-mirror=mirror.gcr.io + context: dashboard + file: dashboard/Dockerfile + push: true + tags: git.chemavx.xyz/chemavx/polymarket-bot-dashboard:${{ steps.tag.outputs.TAG }} + cache-from: type=registry,ref=git.chemavx.xyz/chemavx/polymarket-bot-dashboard:buildcache + cache-to: type=registry,ref=git.chemavx.xyz/chemavx/polymarket-bot-dashboard:buildcache,mode=max - name: Update k8s manifests run: |