-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy path.gitlab-ci.yml
63 lines (56 loc) · 1.47 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
## Define the stages & order of execution
stages:
- CLUSTER-SETUP
- INFRA-SETUP
- CLUSTER-CLEANUP
## Setup kubernetes cluster using Rancher
cluster-create:
image: harshshekhar15/gitlab-job:v2
stage: CLUSTER-SETUP
script:
- chmod 755 ./stages/cluster-setup/setup
- ./stages/cluster-setup/setup
## Deploy Director On-Prem
director-deploy:
image: harshshekhar15/gitlab-job:v2
stage: INFRA-SETUP
dependencies:
- cluster-create
script:
- chmod 755 ./stages/infra-setup/dop
- ./stages/infra-setup/dop
pre-requisites:
image: harshshekhar15/gitlab-job:v2
stage: INFRA-SETUP
dependencies:
- cluster-create
script:
- chmod 755 ./stages/infra-setup/pre-requisites
- ./stages/infra-setup/pre-requisites
basic-sanity-checks:
image: harshshekhar15/gitlab-job:v2
stage: INFRA-SETUP
dependencies:
- cluster-create
script:
- chmod 755 ./stages/infra-setup/basic-sanity-checks
- ./stages/infra-setup/basic-sanity-checks
e2e-metrics:
when: always
image: harshshekhar15/gitlab-job:v2
stage: CLUSTER-CLEANUP
dependencies:
- cluster-create
script:
- chmod 755 ./stages/cluster-cleanup/e2e-metrics
- ./stages/cluster-cleanup/e2e-metrics
## Revert the cluster to previous snapshot
cluster-cleanup:
when: always
image: harshshekhar15/gitlab-job:v2
dependencies:
- cluster-create
stage: CLUSTER-CLEANUP
script:
- chmod 755 ./stages/cluster-cleanup/cleanup
- ./stages/cluster-cleanup/cleanup