woodpecker/.woodpecker/binaries.yml
2022-02-25 12:08:48 +01:00

134 lines
2.6 KiB
YAML

depends_on:
- test
- web
pipeline:
build-web:
image: node:16-alpine
commands:
- cd web/
- yarn install --frozen-lockfile
- yarn build
when:
path:
# related config files
- ".woodpecker/binaries.yml"
- "nfpm/*.yml"
# go source code
- "**/*.go"
- "go.*"
# web source code
- "web/**"
build-server:
group: build
image: golang:1.17
commands:
- make release-server
when:
path:
# related config files
- ".woodpecker/binaries.yml"
- "nfpm/*.yml"
# go source code
- "**/*.go"
- "go.*"
# web source code
- "web/**"
build-agent:
group: build
image: golang:1.17
commands:
- make release-agent
when:
path:
# related config files
- ".woodpecker/binaries.yml"
- "nfpm/*.yml"
# go source code
- "**/*.go"
- "go.*"
# web source code
- "web/**"
build-cli:
group: build
image: golang:1.17
commands:
- make release-cli
when:
path:
# related config files
- ".woodpecker/binaries.yml"
- "nfpm/*.yml"
# go source code
- "**/*.go"
- "go.*"
# web source code
- "web/**"
build-deb-rpm:
group: bundle
image: golang:1.17
commands:
- make bundle
when:
path:
# related config files
- ".woodpecker/binaries.yml"
- "nfpm/*.yml"
# go source code
- "**/*.go"
- "go.*"
# web source code
- "web/**"
checksums:
image: golang:1.17
commands:
- make release-checksums
when:
path:
# related config files
- ".woodpecker/binaries.yml"
- "nfpm/*.yml"
# go source code
- "**/*.go"
- "go.*"
# web source code
- "web/**"
# TODO: upload build artifacts for pushes to ${CI_REPO_DEFAULT_BRANCH}
release-dryrun:
image: golang:1.17
commands:
- ls -la dist/*.*
- cat dist/checksums.txt
when:
path:
# related config files
- ".woodpecker/binaries.yml"
- "nfpm/*.yml"
# go source code
- "**/*.go"
- "go.*"
# web source code
- "web/**"
release:
image: plugins/github-release
secrets:
- source: github_token
target: github_release_api_key
settings:
files:
- dist/*.tar.gz
- dist/*.deb
- dist/*.rpm
- dist/checksums.txt
title: ${CI_COMMIT_TAG##v}
when:
event: tag
# path conditions are ignored for tag events