add CI files
Some checks failed
ci/woodpecker/push/test Pipeline failed
ci/woodpecker/push/build unknown status

add makefile

add fpm conf
This commit is contained in:
Simon Vieille 2024-07-30 21:34:05 +02:00
commit 87e76093a5
Signed by: deblan
GPG key ID: 579388D585F70417
8 changed files with 155 additions and 1 deletions

54
.woodpecker/build.yml Normal file
View file

@ -0,0 +1,54 @@
when:
- event: [pull_request, tag]
- event: push
branch:
- ${CI_REPO_DEFAULT_BRANCH}
- develop
- feature/*
- release/*
- renovate/*
variables:
- &golang_image 'golang:1.22'
depends_on:
- test
steps:
"Add vendor":
image: *golang_image
commands:
- go mod vendor
"Run build":
image: *golang_image
commands:
- make
"Test packaging":
image: deblan/fpm-packager
commands:
- VERSION=test
- ./bin/build-debs.sh "$VERSION"
- ./bin/rename-builds.sh "$VERSION"
when:
event: [push, pull_request]
"Create packages":
image: deblan/fpm-packager
commands:
- VERSION=${CI_COMMIT_TAG/v//}
- ./bin/build-debs.sh "$VERSION"
- ./bin/rename-builds.sh "$VERSION"
when:
event: [tag]
"Publish":
image: plugins/gitea-release
settings:
api_key:
from_secret: gitnet_api_key
base_url: https://gitnet.fr
files: ./build/*
when:
event: [tag]