forked from jarv/cmdchallenge
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
51 lines (44 loc) · 1.01 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
stages:
- build
- test
- deploy
before_script:
- docker info
- pip install -r requirements.txt
- export PATH=$PATH:/usr/local/go/bin
build_runcmd:
image: registry.gitlab.com/jarv/cmdchallenge/ci-image
stage: build
script:
- make build-runcmd
build_docker_image:
image: registry.gitlab.com/jarv/cmdchallenge/ci-image
stage: build
script:
- make build-docker
######################
# TEST
######################
test_runcmd:
image: registry.gitlab.com/jarv/cmdchallenge/ci-image
stage: test
script:
- make test-runcmd
test_challenges:
image: registry.gitlab.com/jarv/cmdchallenge/ci-image
stage: test
script:
- make build-docker
- make test-challenges
######################
# DEPLOY
######################
deploy:
stage: deploy
image: registry.gitlab.com/jarv/cmdchallenge/ci-image
script:
- make build-docker-prod
- docker login -u jarv -p $REGISTRY_ACCESS_TOKEN registry.gitlab.com
- docker push registry.gitlab.com/jarv/cmdchallenge
only:
- master