From 5346e68c5cae3f7e5f5b54da1f088d457eb44918 Mon Sep 17 00:00:00 2001 From: Simon Vieille Date: Sat, 27 May 2023 17:11:11 +0200 Subject: [PATCH] update ci configuration --- .woodpecker.yml | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/.woodpecker.yml b/.woodpecker.yml index e9ff3be..ebd4e3d 100644 --- a/.woodpecker.yml +++ b/.woodpecker.yml @@ -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]