From d2657493b40f5db19d7c40d017463fe8055909d5 Mon Sep 17 00:00:00 2001 From: Robert Kaussow Date: Sun, 19 Sep 2021 21:48:17 +0200 Subject: [PATCH] ci: switch to drone-matrix plugin --- .drone.jsonnet | 4 +- .drone.yml | 538 ++++++++++++++++++++++++------------------------- 2 files changed, 271 insertions(+), 271 deletions(-) diff --git a/.drone.jsonnet b/.drone.jsonnet index 9412db3..46e816b 100644 --- a/.drone.jsonnet +++ b/.drone.jsonnet @@ -167,11 +167,11 @@ local PipelineNotifications = { }, { name: 'matrix', - image: 'plugins/matrix', + image: 'thegeeklab/drone-matrix', settings: { homeserver: { from_secret: 'matrix_homeserver' }, roomid: { from_secret: 'matrix_roomid' }, - template: 'Status: **{{ build.status }}**
Build: [{{ repo.Owner }}/{{ repo.Name }}]({{ build.link }}) ({{ build.branch }}) by {{ build.author }}
Message: {{ build.message }}', + template: 'Status: **{{ build.Status }}**
Build: [{{ repo.Owner }}/{{ repo.Name }}]({{ build.Link }}) ({{ build.Branch }}) by {{ commit.Author }}
Message: {{ commit.Message }}', username: { from_secret: 'matrix_username' }, password: { from_secret: 'matrix_password' }, }, diff --git a/.drone.yml b/.drone.yml index dfd568c..c086f8f 100644 --- a/.drone.yml +++ b/.drone.yml @@ -7,16 +7,16 @@ platform: arch: amd64 steps: -- name: markdownlint - image: thegeeklab/markdownlint-cli - commands: - - markdownlint 'README.md' + - name: markdownlint + image: thegeeklab/markdownlint-cli + commands: + - markdownlint 'README.md' trigger: ref: - - refs/heads/main - - refs/tags/** - - refs/pull/** + - refs/heads/main + - refs/tags/** + - refs/pull/** --- kind: pipeline @@ -27,77 +27,77 @@ platform: arch: amd64 steps: -- name: tags - image: thegeeklab/docker-autotag - environment: - DOCKER_AUTOTAG_FORCE_LATEST: True - DOCKER_AUTOTAG_IGNORE_PRERELEASE: True - DOCKER_AUTOTAG_OUTPUT_FILE: .tags - DOCKER_AUTOTAG_SUFFIX: amd64 - DOCKER_AUTOTAG_VERSION: ${DRONE_TAG} + - name: tags + image: thegeeklab/docker-autotag + environment: + DOCKER_AUTOTAG_FORCE_LATEST: True + DOCKER_AUTOTAG_IGNORE_PRERELEASE: True + DOCKER_AUTOTAG_OUTPUT_FILE: .tags + DOCKER_AUTOTAG_SUFFIX: amd64 + DOCKER_AUTOTAG_VERSION: ${DRONE_TAG} -- name: dryrun - pull: always - image: thegeeklab/drone-docker-buildx:20 - settings: - dockerfile: Dockerfile.amd64 - dry_run: true - password: - from_secret: docker_password - platforms: - - linux/amd64 - repo: thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: docker_username - when: - ref: - - refs/pull/** - depends_on: - - tags + - name: dryrun + pull: always + image: thegeeklab/drone-docker-buildx:20 + settings: + dockerfile: Dockerfile.amd64 + dry_run: true + password: + from_secret: docker_password + platforms: + - linux/amd64 + repo: thegeeklab/${DRONE_REPO_NAME} + username: + from_secret: docker_username + when: + ref: + - refs/pull/** + depends_on: + - tags -- name: publish-dockerhub - pull: always - image: thegeeklab/drone-docker-buildx:20 - settings: - dockerfile: Dockerfile.amd64 - password: - from_secret: docker_password - repo: thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: docker_username - when: - ref: - - refs/heads/main - - refs/tags/** - depends_on: - - tags + - name: publish-dockerhub + pull: always + image: thegeeklab/drone-docker-buildx:20 + settings: + dockerfile: Dockerfile.amd64 + password: + from_secret: docker_password + repo: thegeeklab/${DRONE_REPO_NAME} + username: + from_secret: docker_username + when: + ref: + - refs/heads/main + - refs/tags/** + depends_on: + - tags -- name: publish-quay - pull: always - image: thegeeklab/drone-docker-buildx:20 - settings: - dockerfile: Dockerfile.amd64 - password: - from_secret: quay_password - registry: quay.io - repo: quay.io/thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: quay_username - when: - ref: - - refs/heads/main - - refs/tags/** - depends_on: - - tags + - name: publish-quay + pull: always + image: thegeeklab/drone-docker-buildx:20 + settings: + dockerfile: Dockerfile.amd64 + password: + from_secret: quay_password + registry: quay.io + repo: quay.io/thegeeklab/${DRONE_REPO_NAME} + username: + from_secret: quay_username + when: + ref: + - refs/heads/main + - refs/tags/** + depends_on: + - tags trigger: ref: - - refs/heads/main - - refs/tags/** - - refs/pull/** + - refs/heads/main + - refs/tags/** + - refs/pull/** depends_on: -- test + - test --- kind: pipeline @@ -108,77 +108,77 @@ platform: arch: amd64 steps: -- name: tags - image: thegeeklab/docker-autotag - environment: - DOCKER_AUTOTAG_FORCE_LATEST: True - DOCKER_AUTOTAG_IGNORE_PRERELEASE: True - DOCKER_AUTOTAG_OUTPUT_FILE: .tags - DOCKER_AUTOTAG_SUFFIX: arm64 - DOCKER_AUTOTAG_VERSION: ${DRONE_TAG} + - name: tags + image: thegeeklab/docker-autotag + environment: + DOCKER_AUTOTAG_FORCE_LATEST: True + DOCKER_AUTOTAG_IGNORE_PRERELEASE: True + DOCKER_AUTOTAG_OUTPUT_FILE: .tags + DOCKER_AUTOTAG_SUFFIX: arm64 + DOCKER_AUTOTAG_VERSION: ${DRONE_TAG} -- name: dryrun - pull: always - image: thegeeklab/drone-docker-buildx:20 - settings: - dockerfile: Dockerfile.arm64 - dry_run: true - password: - from_secret: docker_password - platforms: - - linux/arm64/v8 - repo: thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: docker_username - when: - ref: - - refs/pull/** - depends_on: - - tags + - name: dryrun + pull: always + image: thegeeklab/drone-docker-buildx:20 + settings: + dockerfile: Dockerfile.arm64 + dry_run: true + password: + from_secret: docker_password + platforms: + - linux/arm64/v8 + repo: thegeeklab/${DRONE_REPO_NAME} + username: + from_secret: docker_username + when: + ref: + - refs/pull/** + depends_on: + - tags -- name: publish-dockerhub - pull: always - image: thegeeklab/drone-docker-buildx:20 - settings: - dockerfile: Dockerfile.arm64 - password: - from_secret: docker_password - repo: thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: docker_username - when: - ref: - - refs/heads/main - - refs/tags/** - depends_on: - - tags + - name: publish-dockerhub + pull: always + image: thegeeklab/drone-docker-buildx:20 + settings: + dockerfile: Dockerfile.arm64 + password: + from_secret: docker_password + repo: thegeeklab/${DRONE_REPO_NAME} + username: + from_secret: docker_username + when: + ref: + - refs/heads/main + - refs/tags/** + depends_on: + - tags -- name: publish-quay - pull: always - image: thegeeklab/drone-docker-buildx:20 - settings: - dockerfile: Dockerfile.arm64 - password: - from_secret: quay_password - registry: quay.io - repo: quay.io/thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: quay_username - when: - ref: - - refs/heads/main - - refs/tags/** - depends_on: - - tags + - name: publish-quay + pull: always + image: thegeeklab/drone-docker-buildx:20 + settings: + dockerfile: Dockerfile.arm64 + password: + from_secret: quay_password + registry: quay.io + repo: quay.io/thegeeklab/${DRONE_REPO_NAME} + username: + from_secret: quay_username + when: + ref: + - refs/heads/main + - refs/tags/** + depends_on: + - tags trigger: ref: - - refs/heads/main - - refs/tags/** - - refs/pull/** + - refs/heads/main + - refs/tags/** + - refs/pull/** depends_on: -- test + - test --- kind: pipeline @@ -189,77 +189,77 @@ platform: arch: amd64 steps: -- name: tags - image: thegeeklab/docker-autotag - environment: - DOCKER_AUTOTAG_FORCE_LATEST: True - DOCKER_AUTOTAG_IGNORE_PRERELEASE: True - DOCKER_AUTOTAG_OUTPUT_FILE: .tags - DOCKER_AUTOTAG_SUFFIX: arm - DOCKER_AUTOTAG_VERSION: ${DRONE_TAG} + - name: tags + image: thegeeklab/docker-autotag + environment: + DOCKER_AUTOTAG_FORCE_LATEST: True + DOCKER_AUTOTAG_IGNORE_PRERELEASE: True + DOCKER_AUTOTAG_OUTPUT_FILE: .tags + DOCKER_AUTOTAG_SUFFIX: arm + DOCKER_AUTOTAG_VERSION: ${DRONE_TAG} -- name: dryrun - pull: always - image: thegeeklab/drone-docker-buildx:20 - settings: - dockerfile: Dockerfile.arm - dry_run: true - password: - from_secret: docker_password - platforms: - - linux/arm/v7 - repo: thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: docker_username - when: - ref: - - refs/pull/** - depends_on: - - tags + - name: dryrun + pull: always + image: thegeeklab/drone-docker-buildx:20 + settings: + dockerfile: Dockerfile.arm + dry_run: true + password: + from_secret: docker_password + platforms: + - linux/arm/v7 + repo: thegeeklab/${DRONE_REPO_NAME} + username: + from_secret: docker_username + when: + ref: + - refs/pull/** + depends_on: + - tags -- name: publish-dockerhub - pull: always - image: thegeeklab/drone-docker-buildx:20 - settings: - dockerfile: Dockerfile.arm - password: - from_secret: docker_password - repo: thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: docker_username - when: - ref: - - refs/heads/main - - refs/tags/** - depends_on: - - tags + - name: publish-dockerhub + pull: always + image: thegeeklab/drone-docker-buildx:20 + settings: + dockerfile: Dockerfile.arm + password: + from_secret: docker_password + repo: thegeeklab/${DRONE_REPO_NAME} + username: + from_secret: docker_username + when: + ref: + - refs/heads/main + - refs/tags/** + depends_on: + - tags -- name: publish-quay - pull: always - image: thegeeklab/drone-docker-buildx:20 - settings: - dockerfile: Dockerfile.arm - password: - from_secret: quay_password - registry: quay.io - repo: quay.io/thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: quay_username - when: - ref: - - refs/heads/main - - refs/tags/** - depends_on: - - tags + - name: publish-quay + pull: always + image: thegeeklab/drone-docker-buildx:20 + settings: + dockerfile: Dockerfile.arm + password: + from_secret: quay_password + registry: quay.io + repo: quay.io/thegeeklab/${DRONE_REPO_NAME} + username: + from_secret: quay_username + when: + ref: + - refs/heads/main + - refs/tags/** + depends_on: + - tags trigger: ref: - - refs/heads/main - - refs/tags/** - - refs/pull/** + - refs/heads/main + - refs/tags/** + - refs/pull/** depends_on: -- test + - test --- kind: pipeline @@ -270,91 +270,91 @@ platform: arch: amd64 steps: -- name: manifest-dockerhub - image: plugins/manifest - settings: - ignore_missing: true - password: - from_secret: docker_password - spec: manifest.tmpl - username: - from_secret: docker_username - when: - status: - - success + - name: manifest-dockerhub + image: plugins/manifest + settings: + ignore_missing: true + password: + from_secret: docker_password + spec: manifest.tmpl + username: + from_secret: docker_username + when: + status: + - success -- name: manifest-quay - image: plugins/manifest - settings: - ignore_missing: true - password: - from_secret: quay_password - spec: manifest-quay.tmpl - username: - from_secret: quay_username - when: - status: - - success + - name: manifest-quay + image: plugins/manifest + settings: + ignore_missing: true + password: + from_secret: quay_password + spec: manifest-quay.tmpl + username: + from_secret: quay_username + when: + status: + - success -- name: pushrm-dockerhub - pull: always - image: chko/docker-pushrm:1 - environment: - DOCKER_PASS: - from_secret: docker_password - DOCKER_USER: - from_secret: docker_username - PUSHRM_FILE: README.md - PUSHRM_SHORT: Rootless Alpine base image - PUSHRM_TARGET: thegeeklab/${DRONE_REPO_NAME} - when: - status: - - success + - name: pushrm-dockerhub + pull: always + image: chko/docker-pushrm:1 + environment: + DOCKER_PASS: + from_secret: docker_password + DOCKER_USER: + from_secret: docker_username + PUSHRM_FILE: README.md + PUSHRM_SHORT: Rootless Alpine base image + PUSHRM_TARGET: thegeeklab/${DRONE_REPO_NAME} + when: + status: + - success -- name: pushrm-quay - pull: always - image: chko/docker-pushrm:1 - environment: - APIKEY__QUAY_IO: - from_secret: quay_token - PUSHRM_FILE: README.md - PUSHRM_TARGET: quay.io/thegeeklab/${DRONE_REPO_NAME} - when: - status: - - success + - name: pushrm-quay + pull: always + image: chko/docker-pushrm:1 + environment: + APIKEY__QUAY_IO: + from_secret: quay_token + PUSHRM_FILE: README.md + PUSHRM_TARGET: quay.io/thegeeklab/${DRONE_REPO_NAME} + when: + status: + - success -- name: matrix - image: plugins/matrix - settings: - homeserver: - from_secret: matrix_homeserver - password: - from_secret: matrix_password - roomid: - from_secret: matrix_roomid - template: "Status: **{{ build.status }}**
Build: [{{ repo.Owner }}/{{ repo.Name }}]({{ build.link }}) ({{ build.branch }}) by {{ build.author }}
Message: {{ build.message }}" - username: - from_secret: matrix_username - when: - status: - - success - - failure + - name: matrix + image: thegeeklab/drone-matrix + settings: + homeserver: + from_secret: matrix_homeserver + password: + from_secret: matrix_password + roomid: + from_secret: matrix_roomid + template: "Status: **{{ build.Status }}**
Build: [{{ repo.Owner }}/{{ repo.Name }}]({{ build.Link }}) ({{ build.Branch }}) by {{ commit.Author }}
Message: {{ commit.Message }}" + username: + from_secret: matrix_username + when: + status: + - success + - failure trigger: ref: - - refs/heads/main - - refs/tags/** + - refs/heads/main + - refs/tags/** status: - - success - - failure + - success + - failure depends_on: -- build-container-amd64 -- build-container-arm64 -- build-container-arm + - build-container-amd64 + - build-container-arm64 + - build-container-arm --- kind: signature -hmac: 5ba92b782daeae19415d7cecc8bcd0027f539c7e3c2c97794fba97ef8352f331 +hmac: 3a17a1b2f7d0349e5b6d28d858edec39cfd0cdec42a3f8036b4a252ee2f786b2 ...