From 488acf16c188c0fd25375d7a0331e0822ef6aa96 Mon Sep 17 00:00:00 2001 From: Paolo Asperti Date: Tue, 27 Sep 2022 15:25:46 +0200 Subject: [PATCH] gitea container repo --- .drone.yml | 111 ++++++++++++++++++++++++++++++++++++++++++------- manifest2.tmpl | 31 ++++++++++++++ 2 files changed, 127 insertions(+), 15 deletions(-) create mode 100644 manifest2.tmpl diff --git a/.drone.yml b/.drone.yml index fce5b38..a19297c 100644 --- a/.drone.yml +++ b/.drone.yml @@ -36,6 +36,25 @@ steps: event: - tag + - name: build_and_publish2 + image: plugins/docker:linux-amd64 + settings: + dockerfile: Dockerfile + force_tag: true + password: + from_secret: docker_gitea_password + registry: git.asperti.com + repo: git.asperti.com/paspo/docker-ftps + username: + from_secret: docker_gitea_username + tags: + - ${DRONE_TAG}-linux-amd64 + - ${DRONE_SEMVER_MAJOR}.${DRONE_SEMVER_MINOR}-linux-amd64 + - ${DRONE_SEMVER_MAJOR}-linux-amd64 + when: + event: + - tag + --- kind: pipeline type: docker @@ -75,6 +94,25 @@ steps: event: - tag + - name: build_and_publish2 + image: plugins/docker:linux-arm64 + settings: + dockerfile: Dockerfile + force_tag: true + password: + from_secret: docker_gitea_password + registry: git.asperti.com + repo: git.asperti.com/paspo/docker-ftps + username: + from_secret: docker_gitea_username + tags: + - ${DRONE_TAG}-linux-arm64 + - ${DRONE_SEMVER_MAJOR}.${DRONE_SEMVER_MINOR}-linux-arm64 + - ${DRONE_SEMVER_MAJOR}-linux-arm64 + when: + event: + - tag + --- kind: pipeline type: docker @@ -114,27 +152,68 @@ steps: event: - tag + - name: build_and_publish2 + image: plugins/docker:linux-arm + settings: + dockerfile: Dockerfile + force_tag: true + password: + from_secret: docker_gitea_password + registry: git.asperti.com + repo: git.asperti.com/paspo/docker-ftps + username: + from_secret: docker_gitea_username + tags: + - ${DRONE_TAG}-linux-arm + - ${DRONE_SEMVER_MAJOR}.${DRONE_SEMVER_MINOR}-linux-arm + - ${DRONE_SEMVER_MAJOR}-linux-arm + when: + event: + - tag + --- kind: pipeline type: docker name: manifest steps: -- name: manifest - image: plugins/manifest - settings: - force_tag: true - ignore_missing: true - spec: manifest.tmpl - username: - from_secret: docker_username - password: - from_secret: docker_password - tags: - - latest - - ${DRONE_TAG} - - ${DRONE_SEMVER_MAJOR}.${DRONE_SEMVER_MINOR} - - ${DRONE_SEMVER_MAJOR} + - name: manifest + image: plugins/manifest + settings: + force_tag: true + ignore_missing: true + spec: manifest.tmpl + username: + from_secret: docker_username + password: + from_secret: docker_password + tags: + - latest + - ${DRONE_TAG} + - ${DRONE_SEMVER_MAJOR}.${DRONE_SEMVER_MINOR} + - ${DRONE_SEMVER_MAJOR} + when: + event: + - tag + + - name: manifest2 + image: plugins/manifest + settings: + force_tag: true + ignore_missing: true + spec: manifest2.tmpl + username: + from_secret: docker_gitea_username + password: + from_secret: docker_gitea_password + tags: + - latest + - ${DRONE_TAG} + - ${DRONE_SEMVER_MAJOR}.${DRONE_SEMVER_MINOR} + - ${DRONE_SEMVER_MAJOR} + when: + event: + - tag trigger: event: @@ -144,3 +223,5 @@ depends_on: - linux-amd64 - linux-arm64 - linux-arm + + diff --git a/manifest2.tmpl b/manifest2.tmpl new file mode 100644 index 0000000..a589b1f --- /dev/null +++ b/manifest2.tmpl @@ -0,0 +1,31 @@ +image: git.asperti.com/paspo/docker-ftps:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}latest{{/if}} +{{#if build.tags}} +tags: +{{#each build.tags}} + - {{this}} +{{/each}} +{{/if}} +manifests: + - + image: git.asperti.com/paspo/docker-ftps:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64 + platform: + architecture: amd64 + os: linux + - + image: git.asperti.com/paspo/docker-ftps:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64 + platform: + variant: v8 + architecture: arm64 + os: linux + - + image: git.asperti.com/paspo/docker-ftps:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm + platform: + variant: v7 + architecture: arm + os: linux + - + image: git.asperti.com/paspo/docker-ftps:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm + platform: + variant: v6 + architecture: arm + os: linux