-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yaml
44 lines (40 loc) · 1.47 KB
/
.gitlab-ci.yaml
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
default:
image: alpine/k8s:1.28.14
stages:
- upload
application-set:
stage: upload
rules:
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
changes:
- helm/charts/application-set/Chart.yaml
before_script:
- 'export HOME=/tmp'
- 'helm repo add --username gitlab-ci-token --password ${CI_JOB_TOKEN} ${CI_PROJECT_NAME} ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/helm/stable'
- 'helm plugin install https://github.com/chartmuseum/helm-push.git'
script:
- 'helm cm-push helm/charts/application-set/ ${CI_PROJECT_NAME}'
tenant:
stage: upload
rules:
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
changes:
- helm/charts/tenant/Chart.yaml
before_script:
- 'export HOME=/tmp'
- 'helm repo add --username gitlab-ci-token --password ${CI_JOB_TOKEN} ${CI_PROJECT_NAME} ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/helm/stable'
- 'helm plugin install https://github.com/chartmuseum/helm-push.git'
script:
- 'helm cm-push helm/charts/tenant/ ${CI_PROJECT_NAME}'
tenant-gitops:
stage: upload
rules:
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
changes:
- helm/charts/tenant-gitops/Chart.yaml
before_script:
- 'export HOME=/tmp'
- 'helm repo add --username gitlab-ci-token --password ${CI_JOB_TOKEN} ${CI_PROJECT_NAME} ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/helm/stable'
- 'helm plugin install https://github.com/chartmuseum/helm-push.git'
script:
- 'helm cm-push helm/charts/tenant-gitops/ ${CI_PROJECT_NAME}'