aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGabriel A. Giovanini <mail@gabrielgio.me>2022-05-15 16:41:26 +0200
committerGabriel A. Giovanini <mail@gabrielgio.me>2022-05-15 16:41:26 +0200
commit7c7967ebc8f7a1f67965f2300dde39fab0adc340 (patch)
tree89f7de6abe7d7554193fb9a012f990b1bf29309f
parent622fef31c7bdbc0646fbad6ba11ebeb393fb626a (diff)
downloadmacroblog.rs-7c7967ebc8f7a1f67965f2300dde39fab0adc340.tar.gz
macroblog.rs-7c7967ebc8f7a1f67965f2300dde39fab0adc340.tar.bz2
macroblog.rs-7c7967ebc8f7a1f67965f2300dde39fab0adc340.zip
feat: Add release job
-rw-r--r--.gitlab-ci.yml20
1 files changed, 20 insertions, 0 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 3f725d9..fcb17cf 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -1,6 +1,7 @@
stages:
- test
- production
+ - release_job
test:
image: rust:alpine
@@ -28,3 +29,22 @@ production:
- dpl --provider=heroku --app=$HEROKU_APP --api-key=$HEROKU_API_KEY
only:
- master
+
+release_job:
+ stage: release
+ image: rust:alpine
+ rules:
+ - if: $CI_COMMIT_TAG
+ script:
+ paths:
+ - echo "running release_job"
+ - apk add musl-dev
+ - cargo build --release
+ artifacts:
+ - target/release/hyper
+ - target/release/actix
+ release:
+ name: 'Release $CI_COMMIT_TAG'
+ description: 'New macroblog version'
+ tag_name: '$CI_COMMIT_TAG'
+ ref: '$CI_COMMIT_TAG'