Skip to content

Commit

Permalink
feat: Add release stage
Browse files Browse the repository at this point in the history
  • Loading branch information
fotos committed May 28, 2020
1 parent 2045421 commit 337b09e
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,15 @@
variables:
CI_GOLANGCI_LINT_VERSION: "1.18.0"
CI_IMAGE_NAME: "docker.artifacts.lo/$CI_PROJECT_PATH"
CI_RELEASE_IMAGE_NAME: "docker.artifacts.lo/microservices/tools/release"

# Define pipeline stages
# Doc: https://docs.gitlab.com/ee/ci/yaml/README.html#stages
stages:
- build
- check
- test
- release

# Builds a docker image
# Doc: https://docs.gitlab.com/ee/ci/yaml/README.html#stage
Expand Down Expand Up @@ -57,3 +59,17 @@ run:tests:
- check:fmt
tags:
- docker

# Release a new version
release:version:
stage: release
image: $CI_RELEASE_IMAGE_NAME:latest
script:
- npx semantic-release
dependencies:
- run:tests
only:
- master
tags:
- docker
when: manual

0 comments on commit 337b09e

Please sign in to comment.