-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
72 lines (63 loc) · 1.98 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
62
63
64
65
66
67
68
69
70
71
72
stages:
- build
- package
variables:
GIT_STRATEGY: clone
PYTHON_IMAGE: "code.ornl.gov:4567/rse/datastreams/ssm/clients/ssm-rest-python-client/python:3.6"
before_script:
- curl https://code.ornl.gov/rse-deployment/rse-sharables/raw/master/rse-bash-modules.sh -O
- source rse-bash-modules.sh
- func_rse_docker_cleanup
- docker login --username=$CI_REGISTRY_USER --password=$CI_REGISTRY_PASSWORD $CI_REGISTRY
after_script:
- source rse-bash-modules.sh
- func_rse_docker_cleanup
lint:
stage: build
script:
- docker build -f .ci/Dockerfile -t ssm-rest-python-client-lint .
- docker run ssm-rest-python-client-lint poetry run make lint
tags:
- rse-multi-builder
lint-complexity:
stage: build
script:
- docker build -f .ci/Dockerfile -t ssm-rest-python-client-lint .
- docker run ssm-rest-python-client-lint poetry run make lint-complexity
tags:
- rse-multi-builder
allow_failure: true
test:
stage: build
script:
- docker build -f .ci/Dockerfile -t ssm-rest-python-client-test .
- docker run ssm-rest-python-client-test poetry run make test
tags:
- rse-multi-builder
coverage:
stage: build
script:
- docker build -f .ci/Dockerfile -t ssm-rest-python-client-coverage .
- docker run ssm-rest-python-client-coverage poetry run make coverage
tags:
- rse-multi-builder
test-all:
stage: build
script:
- docker build -f .ci/Dockerfile -t ssm-rest-python-client-test-all .
- docker run ssm-rest-python-client-test-all poetry run make test-all
tags:
- rse-multi-builder
only:
- dev
- master
- tags
publish-package:
stage: package
script:
- docker build -f .ci/Dockerfile -t ssm-rest-python-publish .
- docker run ssm-rest-python-publish bash .ci/publish-package.sh gitlab-ci-token $CI_JOB_TOKEN
tags:
- rse-multi-builder
only:
- /^v\d+\.\d+\.\d+.*$/