.gitlab-ci.yml 958 Bytes
Newer Older
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
image: registry.uninett.no/asm/kubernetes-deploy:v0.13
variables:
  KUBE_PROD_DOMAIN: edulab.uninett.no # The main domain for your application.
  KUBE_TEST_DOMAIN: edulab-beta.paas2.uninett.no # A domain which test versions of your application can be launched under.
  HTTP_PORT: '80' # The port number of the web server.
  REPLICAS: '1'
stages:
  - build
#  - test
  - staging
  - production
build:
  stage: build
  script:
    - build
  only:
    - branches
production:
  stage: production
  script:
    - deploy etc/kubernetes/deployment.yaml
  environment:
    name: production
    url: https://$KUBE_PROD_DOMAIN
  variables:
    URL: https://$KUBE_PROD_DOMAIN
  when: manual
  only:
    - master
staging:
  stage: staging
  script:
    - deploy etc/kubernetes/deployment.yaml
  environment:
    name: staging
    url: https://$KUBE_TEST_DOMAIN
  variables:
    URL: https://$KUBE_TEST_DOMAIN
  only:
    - master