.gitlab-ci.yml 818 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11
variables:
  GIT_STRATEGY: fetch
  GIT_SUBMODULE_STRATEGY: recursive

stages:
  - build
  - deploy

# Stage: build
##############################################################################

Steffen Vogel's avatar
Steffen Vogel committed
12
build:image:
13
  stage: build
Steffen Vogel's avatar
Steffen Vogel committed
14 15
  before_script:
    - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
16
  script:
Steffen Vogel's avatar
Steffen Vogel committed
17
    - make upload
18
  tags:
Steffen Vogel's avatar
Steffen Vogel committed
19 20
    - shell
    - linux
21 22 23 24

# Stage: deploy
##############################################################################

Steffen Vogel's avatar
Steffen Vogel committed
25
deploy:kubernetes:
26
  stage: deploy
Steffen Vogel's avatar
Steffen Vogel committed
27 28 29 30 31 32 33
  variables:
    KUBECONFIG: /root/.kube/config
  image: registry.git.rwth-aachen.de/acs/cloud/kubernetes/deployment
  before_script:
    - mkdir -p $(dirname ${KUBECONFIG})
    - echo "${KUBECONFIG_ENCODED}" | base64 -d > ${KUBECONFIG}
    - kubectl version
34
  script:
35
    - make deploy
36
  tags:
Steffen Vogel's avatar
Steffen Vogel committed
37
    - docker