From 0d0ac2936abfc7d7f42bdfcb97eea21c8364c56c Mon Sep 17 00:00:00 2001 From: shats Date: Mon, 20 Apr 2026 01:36:21 +0700 Subject: [PATCH] CI: build v5 branch with Docker tags v5 only Made-with: Cursor --- .gitea/workflows/docker-publish.yml | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/docker-publish.yml b/.gitea/workflows/docker-publish.yml index ed1803f..58f85b4 100644 --- a/.gitea/workflows/docker-publish.yml +++ b/.gitea/workflows/docker-publish.yml @@ -5,6 +5,7 @@ on: branches: - main - v4 + - v5 - tabler - v3 workflow_dispatch: @@ -29,7 +30,31 @@ jobs: username: ${{ gitea.actor }} password: ${{ secrets.ACTIONS_PAT }} - - name: Build and push Docker image + # Ветка v5: в реестр только теги v5 / v5- (без latest) + - name: Build and push Docker image (v5) + if: ${{ gitea.ref_name == 'v5' }} + uses: docker/build-push-action@v5 + with: + context: . + file: ./Dockerfile.fast + push: true + platforms: linux/amd64 + cache-from: type=gha + cache-to: type=gha,mode=max + tags: | + git.shts.su/${{ gitea.repository }}:v5 + git.shts.su/${{ gitea.repository }}:v5-${{ gitea.sha }} + labels: | + org.opencontainers.image.title=RouterOS Manager + org.opencontainers.image.description=RouterOS Manager for domains and AS management + org.opencontainers.image.version=v5 + org.opencontainers.image.revision=${{ gitea.sha }} + org.opencontainers.image.created=${{ gitea.event.head_commit.timestamp }} + build-args: | + BUILDKIT_INLINE_CACHE=1 + + - name: Build and push Docker image (main и прочие ветки) + if: ${{ gitea.ref_name != 'v5' }} uses: docker/build-push-action@v5 with: context: .