--- kind: pipeline type: docker name: testing platform: os: linux arch: amd64 steps: - name: vet image: golang:1.12 commands: - go vet ./... volumes: - name: gopath path: /go - name: test image: golang:1.12 commands: - go test -cover ./... volumes: - name: gopath path: /go volumes: - name: gopath temp: {} trigger: ref: - refs/heads/master - refs/tags/** - refs/pull/** --- kind: pipeline type: docker name: build-container-amd64 platform: os: linux arch: amd64 steps: - name: build-push image: golang:1.12 commands: - go build -v -ldflags "-X main.version=${DRONE_COMMIT_SHA:0:8}" -a -tags netgo -o release/amd64/github-releases-notifier environment: CGO_ENABLED: 0 when: event: exclude: - tag - name: build-tag image: golang:1.12 commands: - go build -v -ldflags "-X main.version=${DRONE_TAG##v}" -a -tags netgo -o release/amd64/github-releases-notifier environment: CGO_ENABLED: 0 when: event: - tag - name: executable image: golang:1.12 commands: - ./release/amd64/github-releases-notifier --help - name: dryrun image: plugins/docker settings: dockerfile: docker/Dockerfile.amd64 dry_run: true password: from_secret: docker_password repo: xoxys/github-releases-notifier tags: amd64 username: from_secret: docker_username when: event: - pull_request - name: publish image: plugins/docker settings: auto_tag: true auto_tag_suffix: amd64 dockerfile: docker/Dockerfile.amd64 password: from_secret: docker_password repo: xoxys/github-releases-notifier username: from_secret: docker_username when: event: exclude: - pull_request trigger: ref: - refs/heads/master - refs/tags/** - refs/pull/** depends_on: - testing --- kind: pipeline type: docker name: build-container-arm64 platform: os: linux arch: arm64 steps: - name: build-push image: golang:1.12 commands: - go build -v -ldflags "-X main.version=${DRONE_COMMIT_SHA:0:8}" -a -tags netgo -o release/arm64/github-releases-notifier environment: CGO_ENABLED: 0 when: event: exclude: - tag - name: build-tag image: golang:1.12 commands: - go build -v -ldflags "-X main.version=${DRONE_TAG##v}" -a -tags netgo -o release/arm64/github-releases-notifier environment: CGO_ENABLED: 0 when: event: - tag - name: executable image: golang:1.12 commands: - ./release/arm64/github-releases-notifier --help - name: dryrun image: plugins/docker settings: dockerfile: docker/Dockerfile.arm64 dry_run: true password: from_secret: docker_password repo: xoxys/github-releases-notifier tags: arm64 username: from_secret: docker_username when: event: - pull_request - name: publish image: plugins/docker settings: auto_tag: true auto_tag_suffix: arm64 dockerfile: docker/Dockerfile.arm64 password: from_secret: docker_password repo: xoxys/github-releases-notifier username: from_secret: docker_username when: event: exclude: - pull_request trigger: ref: - refs/heads/master - refs/tags/** - refs/pull/** depends_on: - testing --- kind: pipeline type: docker name: build-container-arm platform: os: linux arch: arm steps: - name: build-push image: golang:1.12 commands: - go build -v -ldflags "-X main.version=${DRONE_COMMIT_SHA:0:8}" -a -tags netgo -o release/arm/github-releases-notifier environment: CGO_ENABLED: 0 when: event: exclude: - tag - name: build-tag image: golang:1.12 commands: - go build -v -ldflags "-X main.version=${DRONE_TAG##v}" -a -tags netgo -o release/arm/github-releases-notifier environment: CGO_ENABLED: 0 when: event: - tag - name: executable image: golang:1.12 commands: - ./release/arm/github-releases-notifier --help - name: dryrun image: plugins/docker settings: dockerfile: docker/Dockerfile.arm dry_run: true password: from_secret: docker_password repo: xoxys/github-releases-notifier tags: arm username: from_secret: docker_username when: event: - pull_request - name: publish image: plugins/docker settings: auto_tag: true auto_tag_suffix: arm dockerfile: docker/Dockerfile.arm password: from_secret: docker_password repo: xoxys/github-releases-notifier username: from_secret: docker_username when: event: exclude: - pull_request trigger: ref: - refs/heads/master - refs/tags/** - refs/pull/** depends_on: - testing --- kind: pipeline type: docker name: notification platform: os: linux arch: amd64 steps: - name: manifest image: plugins/manifest settings: auto_tag: true ignore_missing: true password: from_secret: docker_password spec: docker/manifest.tmpl username: from_secret: docker_username when: status: - success - name: readme image: sheogorath/readme-to-dockerhub environment: DOCKERHUB_PASSWORD: from_secret: docker_password DOCKERHUB_REPO_NAME: github-releases-notifier DOCKERHUB_REPO_PREFIX: xoxys DOCKERHUB_USERNAME: from_secret: docker_username README_PATH: README.md SHORT_DESCRIPTION: Receive Slack notifications for new GitHub releases - name: microbadger image: plugins/webhook settings: urls: from_secret: microbadger_url 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 trigger: ref: - refs/heads/master - refs/tags/** status: - success - failure depends_on: - build-container-amd64 - build-container-arm64 - build-container-arm --- kind: signature hmac: 48723ecce577b6addd70c457f07360a1986bbb43b56034619bf9843efc797a4a ...