aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.drone.yml127
-rw-r--r--docker/manifest.rootless.tmpl6
-rw-r--r--docker/manifest.tmpl6
3 files changed, 133 insertions, 6 deletions
diff --git a/.drone.yml b/.drone.yml
index 1075baa355..10444d689f 100644
--- a/.drone.yml
+++ b/.drone.yml
@@ -856,6 +856,67 @@ steps:
---
kind: pipeline
+name: docker-linux-amd64-release-branch
+
+platform:
+ os: linux
+ arch: amd64
+
+depends_on:
+ - testing-amd64
+ - testing-arm64
+
+trigger:
+ ref:
+ - "refs/heads/release/v*"
+ event:
+ exclude:
+ - cron
+
+steps:
+ - name: fetch-tags
+ image: docker:git
+ commands:
+ - git fetch --tags --force
+
+ - name: publish
+ pull: always
+ image: techknowlogick/drone-docker:latest
+ settings:
+ auto_tag: false
+ tags: ${DRONE_BRANCH##release/v}-dev-linux-amd64
+ repo: gitea/gitea
+ build_args:
+ - GOPROXY=https://goproxy.cn
+ password:
+ from_secret: docker_password
+ username:
+ from_secret: docker_username
+ when:
+ event:
+ exclude:
+ - pull_request
+
+ - name: publish-rootless
+ image: techknowlogick/drone-docker:latest
+ settings:
+ dockerfile: Dockerfile.rootless
+ auto_tag: false
+ tags: ${DRONE_BRANCH##release/v}-dev-linux-amd64-rootless
+ repo: gitea/gitea
+ build_args:
+ - GOPROXY=https://goproxy.cn
+ password:
+ from_secret: docker_password
+ username:
+ from_secret: docker_username
+ when:
+ event:
+ exclude:
+ - pull_request
+
+---
+kind: pipeline
type: docker
name: docker-linux-arm64-dry-run
@@ -1010,6 +1071,68 @@ steps:
event:
exclude:
- pull_request
+
+---
+kind: pipeline
+name: docker-linux-arm64-release-branch
+
+platform:
+ os: linux
+ arch: arm64
+
+depends_on:
+ - testing-amd64
+ - testing-arm64
+
+trigger:
+ ref:
+ - "refs/heads/release/v*"
+ event:
+ exclude:
+ - cron
+
+steps:
+ - name: fetch-tags
+ image: docker:git
+ commands:
+ - git fetch --tags --force
+
+ - name: publish
+ pull: always
+ image: techknowlogick/drone-docker:latest
+ settings:
+ auto_tag: false
+ tags: ${DRONE_BRANCH##release/v}-dev-linux-arm64
+ repo: gitea/gitea
+ build_args:
+ - GOPROXY=https://goproxy.cn
+ password:
+ from_secret: docker_password
+ username:
+ from_secret: docker_username
+ when:
+ event:
+ exclude:
+ - pull_request
+
+ - name: publish-rootless
+ image: techknowlogick/drone-docker:latest
+ settings:
+ dockerfile: Dockerfile.rootless
+ auto_tag: false
+ tags: ${DRONE_BRANCH##release/v}-dev-linux-arm64-rootless
+ repo: gitea/gitea
+ build_args:
+ - GOPROXY=https://goproxy.cn
+ password:
+ from_secret: docker_password
+ username:
+ from_secret: docker_username
+ when:
+ event:
+ exclude:
+ - pull_request
+
---
kind: pipeline
type: docker
@@ -1098,6 +1221,8 @@ trigger:
depends_on:
- docker-linux-amd64-release
- docker-linux-arm64-release
+ - docker-linux-amd64-release-branch
+ - docker-linux-arm64-release-branch
---
kind: pipeline
@@ -1131,6 +1256,8 @@ depends_on:
- docker-linux-arm64-release
- docker-linux-amd64-release-version
- docker-linux-arm64-release-version
+ - docker-linux-amd64-release-branch
+ - docker-linux-arm64-release-branch
- docker-manifest
- docker-manifest-version
- docs
diff --git a/docker/manifest.rootless.tmpl b/docker/manifest.rootless.tmpl
index c488934ea3..9559416470 100644
--- a/docker/manifest.rootless.tmpl
+++ b/docker/manifest.rootless.tmpl
@@ -1,4 +1,4 @@
-image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#equal build.ref "refs/heads/main"}}dev{{else}}{{trimPrefix "refs/heads/release/v" build.ref}}-dev{{/equal}}{{/if}}-rootless
+image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#if (hasPrefix "refs/heads/release/v" build.ref)}}{{trimPrefix "refs/heads/release/v" build.ref}}-{{/if}}dev{{/if}}-rootless
{{#if build.tags}}
tags:
{{#each build.tags}}
@@ -8,12 +8,12 @@ tags:
{{/if}}
manifests:
-
- image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#equal build.ref "refs/heads/main"}}dev{{else}}{{trimPrefix "refs/heads/release/v" build.ref}}-dev{{/equal}}{{/if}}-linux-amd64-rootless
+ image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#if (hasPrefix "refs/heads/release/v" build.ref)}}{{trimPrefix "refs/heads/release/v" build.ref}}-{{/if}}dev{{/if}}-linux-amd64-rootless
platform:
architecture: amd64
os: linux
-
- image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#equal build.ref "refs/heads/main"}}dev{{else}}{{trimPrefix "refs/heads/release/v" build.ref}}-dev{{/equal}}{{/if}}-linux-arm64-rootless
+ image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#if (hasPrefix "refs/heads/release/v" build.ref)}}{{trimPrefix "refs/heads/release/v" build.ref}}-{{/if}}dev{{/if}}-linux-arm64-rootless
platform:
architecture: arm64
os: linux
diff --git a/docker/manifest.tmpl b/docker/manifest.tmpl
index 2d125c96ca..4cd4ea4ea2 100644
--- a/docker/manifest.tmpl
+++ b/docker/manifest.tmpl
@@ -1,4 +1,4 @@
-image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#equal build.ref "refs/heads/main"}}dev{{else}}{{trimPrefix "refs/heads/release/v" build.ref}}-dev{{/equal}}{{/if}}
+image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#if (hasPrefix "refs/heads/release/v" build.ref)}}{{trimPrefix "refs/heads/release/v" build.ref}}-{{/if}}dev{{/if}}
{{#if build.tags}}
tags:
{{#each build.tags}}
@@ -8,12 +8,12 @@ tags:
{{/if}}
manifests:
-
- image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#equal build.ref "refs/heads/main"}}dev{{else}}{{trimPrefix "refs/heads/release/v" build.ref}}-dev{{/equal}}{{/if}}-linux-amd64
+ image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#if (hasPrefix "refs/heads/release/v" build.ref)}}{{trimPrefix "refs/heads/release/v" build.ref}}-{{/if}}dev{{/if}}-linux-amd64
platform:
architecture: amd64
os: linux
-
- image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#equal build.ref "refs/heads/main"}}dev{{else}}{{trimPrefix "refs/heads/release/v" build.ref}}-dev{{/equal}}{{/if}}-linux-arm64
+ image: gitea/gitea:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}{{#if (hasPrefix "refs/heads/release/v" build.ref)}}{{trimPrefix "refs/heads/release/v" build.ref}}-{{/if}}dev{{/if}}-linux-arm64
platform:
architecture: arm64
os: linux