-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
39 lines (35 loc) · 939 Bytes
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
image: microsoft/dotnet:sdk
stages:
- build
- package
build-dotnet:
stage: build
tags:
- short-jobs
script:
- dotnet restore
- dotnet publish -c Debug -o build
artifacts:
untracked: false
expire_in: 2 days
paths:
- build/
package-into-docker:
image: docker.slock.it/build-images/deployment
stage: package
only:
- /^v[0-9]+.[0-9]+.[0-9]+$/
except:
- branches
dependencies:
- build-dotnet
tags:
- short-jobs
services:
- docker:dind
script:
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
- docker build --build-arg CI_VERSION=voting-importer@${CI_COMMIT_REF_NAME} -t $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME .
- docker push $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME
- sentry-cli releases new -p voting-importer voting-importer@${CI_COMMIT_REF_NAME}
- sentry-cli releases set-commits --auto voting-importer@${CI_COMMIT_REF_NAME}