2020-01-19 17:55:03 +05:30
|
|
|
---
|
|
|
|
kind: pipeline
|
2020-01-26 09:13:05 +05:30
|
|
|
name: compliance
|
2020-01-19 17:55:03 +05:30
|
|
|
|
|
|
|
platform:
|
|
|
|
os: linux
|
2020-01-26 09:13:05 +05:30
|
|
|
arch: arm64
|
2020-01-19 17:55:03 +05:30
|
|
|
|
2020-01-26 09:13:05 +05:30
|
|
|
trigger:
|
|
|
|
event:
|
|
|
|
- pull_request
|
2020-01-19 17:55:03 +05:30
|
|
|
|
2020-01-26 09:13:05 +05:30
|
|
|
steps:
|
2020-01-19 17:55:03 +05:30
|
|
|
- name: build
|
|
|
|
pull: always
|
2023-02-28 03:29:03 +05:30
|
|
|
image: golang:1.20
|
2020-01-19 17:55:03 +05:30
|
|
|
environment:
|
2022-06-22 06:57:24 +05:30
|
|
|
GOPROXY: https://goproxy.io,direct
|
2020-01-19 17:55:03 +05:30
|
|
|
commands:
|
2020-01-26 09:13:05 +05:30
|
|
|
- go test -race ./...
|
|
|
|
- go build
|
|
|
|
|
|
|
|
- name: check
|
|
|
|
pull: always
|
2023-02-28 03:29:03 +05:30
|
|
|
image: golang:1.20
|
2020-01-26 09:13:05 +05:30
|
|
|
environment:
|
2022-06-22 06:57:24 +05:30
|
|
|
GOPROXY: https://goproxy.io,direct
|
2020-01-26 09:13:05 +05:30
|
|
|
commands:
|
|
|
|
- make lint
|
2020-01-19 17:55:03 +05:30
|
|
|
|
|
|
|
- name: discord
|
|
|
|
pull: always
|
|
|
|
image: appleboy/drone-discord:1
|
|
|
|
environment:
|
|
|
|
DISCORD_WEBHOOK_ID:
|
|
|
|
from_secret: discord_webhook_id
|
|
|
|
DISCORD_WEBHOOK_TOKEN:
|
|
|
|
from_secret: discord_webhook_token
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- tag
|
|
|
|
status:
|
|
|
|
- changed
|
|
|
|
- failure
|
|
|
|
|
2020-01-26 09:13:05 +05:30
|
|
|
---
|
|
|
|
kind: pipeline
|
|
|
|
name: release
|
|
|
|
|
|
|
|
platform:
|
|
|
|
os: linux
|
|
|
|
arch: amd64
|
|
|
|
|
2020-01-19 17:55:03 +05:30
|
|
|
trigger:
|
|
|
|
branch:
|
2022-08-22 21:23:51 +05:30
|
|
|
- main
|
2020-01-26 09:13:05 +05:30
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- tag
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: fetch-tags
|
|
|
|
pull: always
|
|
|
|
image: docker:git
|
|
|
|
commands:
|
|
|
|
- git fetch --tags --force
|
|
|
|
|
|
|
|
- name: release
|
|
|
|
pull: always
|
|
|
|
image: techknowlogick/xgo:latest
|
|
|
|
environment:
|
2022-06-22 06:57:24 +05:30
|
|
|
GOPROXY: https://goproxy.io,direct
|
2020-01-26 09:13:05 +05:30
|
|
|
commands:
|
|
|
|
- export PATH=$PATH:$GOPATH/bin
|
|
|
|
- make release
|
|
|
|
|
2022-08-22 21:23:51 +05:30
|
|
|
- name: bucket-main
|
2020-01-26 09:13:05 +05:30
|
|
|
pull: always
|
2021-10-09 00:27:05 +05:30
|
|
|
image: woodpeckerci/plugin-s3:latest
|
2020-01-26 09:13:05 +05:30
|
|
|
settings:
|
2023-02-08 03:35:57 +05:30
|
|
|
acl:
|
|
|
|
from_secret: aws_s3_acl
|
|
|
|
region:
|
|
|
|
from_secret: aws_s3_region
|
|
|
|
bucket:
|
|
|
|
from_secret: aws_s3_bucket
|
|
|
|
endpoint:
|
|
|
|
from_secret: aws_s3_endpoint
|
|
|
|
path_style:
|
|
|
|
from_secret: aws_s3_path_style
|
2020-01-27 01:13:59 +05:30
|
|
|
source: "dist/release/*"
|
|
|
|
strip_prefix: dist/release/
|
2022-08-22 21:23:51 +05:30
|
|
|
target: /changelog-tool/main
|
2020-01-26 09:13:05 +05:30
|
|
|
environment:
|
|
|
|
AWS_ACCESS_KEY_ID:
|
|
|
|
from_secret: aws_access_key_id
|
|
|
|
AWS_SECRET_ACCESS_KEY:
|
|
|
|
from_secret: aws_secret_access_key
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
|
|
|
|
- name: bucket-tag
|
|
|
|
pull: always
|
2021-10-09 00:27:05 +05:30
|
|
|
image: woodpeckerci/plugin-s3:latest
|
2020-01-26 09:13:05 +05:30
|
|
|
settings:
|
2023-02-08 03:35:57 +05:30
|
|
|
acl:
|
|
|
|
from_secret: aws_s3_acl
|
|
|
|
region:
|
|
|
|
from_secret: aws_s3_region
|
|
|
|
bucket:
|
|
|
|
from_secret: aws_s3_bucket
|
|
|
|
endpoint:
|
|
|
|
from_secret: aws_s3_endpoint
|
|
|
|
path_style:
|
|
|
|
from_secret: aws_s3_path_style
|
2020-01-27 01:13:59 +05:30
|
|
|
source: "dist/release/*"
|
|
|
|
strip_prefix: dist/release/
|
2020-01-26 09:13:05 +05:30
|
|
|
target: "/changelog-tool/${DRONE_TAG##v}"
|
|
|
|
environment:
|
|
|
|
AWS_ACCESS_KEY_ID:
|
|
|
|
from_secret: aws_access_key_id
|
|
|
|
AWS_SECRET_ACCESS_KEY:
|
|
|
|
from_secret: aws_secret_access_key
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- tag
|
|
|
|
|
|
|
|
- name: gitea
|
|
|
|
pull: always
|
|
|
|
image: plugins/gitea-release:1
|
|
|
|
settings:
|
|
|
|
api_key:
|
|
|
|
from_secret: gitea_token
|
|
|
|
base_url: https://gitea.com
|
|
|
|
files:
|
2020-01-27 08:22:04 +05:30
|
|
|
- "dist/release/*"
|
2020-01-26 09:13:05 +05:30
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- tag
|