update ci configuration
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful

This commit is contained in:
Simon Vieille 2023-05-27 17:11:11 +02:00
parent 61b1cd18cd
commit 5346e68c5c
Signed by: deblan
GPG key ID: 579388D585F70417

View file

@ -1,5 +1,7 @@
variables:
- &golang "golang:1.19"
- &volumes
- /var/www/html/artifacts/capture/deblan:/artifacts
pipeline:
test:
@ -9,12 +11,18 @@ pipeline:
build:
image: *golang
volumes: *volumes
commands:
- go build
- ART=/artifacts/deblan/capture
- test -d $ART || mkdir $ART
- cp capture $ART/capture-latest
- TAG="${CI_COMMIT_TAG}"
- test -n "$TAG" && cp -v capture "$ART/capture-$TAG" || true
volumes:
- /var/www/html/artifacts:/artifacts
- go build -o /artifacts/capture
push-release:
image: plugins/gitea-release
volumes: *volumes
settings:
api_key:
from_secret: gitnet_api_key
base_url: https://gitnet.fr
note: ${CI_COMMIT_MESSAGE}
files: /artifacts/capture
when:
event: [tag]