This repository has been archived by the owner on Jul 9, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
61 lines (55 loc) · 1.57 KB
/
.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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
###############################
# This file is auto-generated #
###############################
variables:
APP_NAME: decorder
stages:
- test
- build
- release
test:
stage: test
image: golang:1.19.0@sha256:d72a2944621f0f4027983e094bdf9464d26459c17efe732320043b84c91e51e7
before_script:
- set -eu
- if [[ -f .env.pipeline ]];then cp .env.pipeline .env;fi
- mkdir -p ~/.ssh
- touch ~/.ssh/known_hosts
- ssh-keyscan gitlab.com > ~/.ssh/known_hosts
retry: 2
script:
- '### run tests ###'
- make test
- make test-cover
lint:source-code:
stage: test
image: golangci/golangci-lint:v1.48.0-alpine@sha256:e9ce901b7974d641d6288b070fc619d199a823d0f696563fec8be90f19789b57
script:
- '### run linter ###'
- golangci-lint run ./...
license-check:
stage: test
image: golang:1.19.0@sha256:d72a2944621f0f4027983e094bdf9464d26459c17efe732320043b84c91e51e7
before_script:
- set -eu
- if [[ -f .env.pipeline ]];then cp .env.pipeline .env;fi
- mkdir -p ~/.ssh
- touch ~/.ssh/known_hosts
- ssh-keyscan gitlab.com > ~/.ssh/known_hosts
script:
- '### run license-check ###'
- make check-licenses
artifacts:
paths:
- LICENSES-3RD-PARTY
expire_in: 7 days
pages:
stage: release
image: golang:1.19.0@sha256:d72a2944621f0f4027983e094bdf9464d26459c17efe732320043b84c91e51e7
only:
- tags
script:
- make gitlab-pages
artifacts:
paths:
- public/