.gitlab-ci.yml 2.21 KB
Newer Older
Stefan Dähling's avatar
add ci  
Stefan Dähling committed
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
stages:
  - build
  - test
  - deploy

amsbuild:
  stage: build
  script:
    - export GOPATH=$HOME/go
    - docker build -f build/docker/ams/Dockerfile -t ams .

agencybuild:
  stage: build
  script:
    - export GOPATH=$HOME/go
    - docker build -f build/docker/agency/Dockerfile -t agency .

loggerbuild:
  stage: build
  script:
    - export GOPATH=$HOME/go
    - docker build -f build/docker/logger/Dockerfile -t logger .

dfbuild:
  stage: build
  script:
    - export GOPATH=$HOME/go
    - docker build -f build/docker/df/Dockerfile -t df .
    
stubbuild:
  stage: build
  script:
    - export GOPATH=$HOME/go
    - cd cmd/kubestub
    - CGO_ENABLED=0 GOOS=linux go build main.go

# amstest:
#   stage: test
#   only:
#     - master
#   script:
#     - cd pkg/ams
#     - CGO_ENABLED=0 go test -coverpkg=./...

agencytest:
  stage: test
  script:
    - cd pkg/agency
    - CGO_ENABLED=0 go test -coverpkg=./...

loggertest:
  stage: test
  script:
    - cd pkg/logger
    - CGO_ENABLED=0 go test -coverpkg=./...

amsdeploy:
  stage: deploy
  only:
    - master
  script:
    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.git.rwth-aachen.de
    - docker tag ams registry.git.rwth-aachen.de/acs/public/cloud/mas/clonemap/ams
    - docker push registry.git.rwth-aachen.de/acs/public/cloud/mas/clonemap/ams

agencydeploy:
  stage: deploy
  only:
    - master
  script:
Stefan Dähling's avatar
ci fix    
Stefan Dähling committed
71
    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.git.rwth-aachen.de
Stefan Dähling's avatar
add ci  
Stefan Dähling committed
72
73
74
75
76
77
78
79
    - docker tag agency registry.git.rwth-aachen.de/acs/public/cloud/mas/clonemap/agency
    - docker push registry.git.rwth-aachen.de/acs/public/cloud/mas/clonemap/agency

loggerdeploy:
  stage: deploy
  only:
    - master
  script:
Stefan Dähling's avatar
ci fix    
Stefan Dähling committed
80
    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.git.rwth-aachen.de
Stefan Dähling's avatar
add ci  
Stefan Dähling committed
81
82
83
84
85
86
87
88
    - docker tag logger registry.git.rwth-aachen.de/acs/public/cloud/mas/clonemap/logger
    - docker push registry.git.rwth-aachen.de/acs/public/cloud/mas/clonemap/logger

dfdeploy:
  stage: deploy
  only:
    - master
  script:
Stefan Dähling's avatar
ci fix    
Stefan Dähling committed
89
    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.git.rwth-aachen.de
Stefan Dähling's avatar
add ci  
Stefan Dähling committed
90
91
    - docker tag df registry.git.rwth-aachen.de/acs/public/cloud/mas/clonemap/df
    - docker push registry.git.rwth-aachen.de/acs/public/cloud/mas/clonemap/df