-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy path.gitlab-ci.yml
39 lines (36 loc) · 967 Bytes
/
.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
stages:
- test
- build
- deploy
Lint:
image:
name: alpine/helm
entrypoint: ["/bin/sh", "-c"]
stage: test
script:
- helm lint charts/*
# - helm lint charts/*/charts/*
Build:
image:
name: alpine/helm
entrypoint: ["bin/sh", "-c"]
stage: build
script:
- mkdir -p ./public
- for chart in charts/*; do helm dependency update $chart; done
- helm package charts/* --destination ./public
- helm repo index --url https://charts.pledra.com .
- mv index.yaml ./public
artifacts:
paths:
- public
Deploy:
image: google/cloud-sdk:latest
stage: deploy
script:
# Login to gcloud
- echo $GCE_SERVICE_ACCOUNT_JSON > /service_account.json
# Authenticate to gain access to gcloud services for this project
- gcloud auth activate-service-account --key-file=/service_account.json --project=pledra-1
# Upload packaged chart to bucket
- gsutil -m cp -r ./public/* gs://pledra-charts