File tree 14 files changed +152
-100
lines changed
14 files changed +152
-100
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ name : Lint and Test Charts
2
+
3
+ on : pull_request
4
+
5
+ jobs :
6
+ lint-test :
7
+ runs-on : ubuntu-latest
8
+ steps :
9
+ - name : Checkout
10
+ uses : actions/checkout@v2
11
+ with :
12
+ fetch-depth : 0
13
+
14
+ - name : Set up Helm
15
+ uses : azure/setup-helm@v1
16
+ with :
17
+ version : v3.4.1
18
+
19
+ # Python is required because `ct lint` runs Yamale (https://github.com/23andMe/Yamale) and
20
+ # yamllint (https://github.com/adrienverge/yamllint) which require Python
21
+ - name : Set up Python
22
+ uses : actions/setup-python@v2
23
+ with :
24
+ python-version : 3.7
25
+
26
+ - name : Set up chart-testing
27
+
28
+ with :
29
+ version : v3.3.0
30
+
31
+ - name : Run chart-testing (list-changed)
32
+ id : list-changed
33
+ run : |
34
+ changed=$(ct list-changed --config ct.yaml)
35
+ if [[ -n "$changed" ]]; then
36
+ echo "::set-output name=changed::true"
37
+ fi
38
+
39
+ - name : Run chart-testing (lint)
40
+ run : ct lint --config ct.yaml
41
+
42
+ - name : Create kind cluster
43
+
44
+ if : steps.list-changed.outputs.changed == 'true'
45
+
46
+ - name : Run chart-testing (install)
47
+ run : ct install --config ct.yaml
Original file line number Diff line number Diff line change
1
+ name : Release Charts
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+
8
+ jobs :
9
+ release :
10
+ runs-on : ubuntu-latest
11
+ steps :
12
+ - name : Checkout
13
+ uses : actions/checkout@v2
14
+ with :
15
+ fetch-depth : 0
16
+
17
+ - name : Configure Git
18
+ run : |
19
+ git config user.name "$GITHUB_ACTOR"
20
+ git config user.email "[email protected] "
21
+
22
+ - name : Install Helm
23
+ uses : azure/setup-helm@v1
24
+ with :
25
+ version : v3.4.1
26
+
27
+ - name : Add dependency chart repos
28
+ run : |
29
+ helm repo add bitnami https://charts.bitnami.com/bitnami
30
+
31
+ - name : Run chart-releaser
32
+
33
+ with :
34
+ charts_dir : charts
35
+ config : cr.yaml
36
+ env :
37
+ CR_TOKEN : " ${{ secrets.GITHUB_TOKEN }}"
Original file line number Diff line number Diff line change @@ -10,5 +10,4 @@ since Helm hub was announced having separate repositories aggregated by the hub
10
10
11
11
## Acknowledgements
12
12
13
- [ Hidetake Iwata] ( https://github.com/int128 ) since I've borrowed his ` publish.sh ` and ` .circleci/config.yml ` to have
14
- a functional initial version
13
+ [ charts-repo-actions-demo] ( https://github.com/helm/charts-repo-actions-demo ) , used to produce this CI flow
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ apiVersion: v1
2
2
appVersion : " 1.9"
3
3
description : A Helm chart for registry creds
4
4
name : registry-creds
5
- version : 1.1.3
5
+ version : 1.2.0
6
6
home : https://hub.docker.com/r/upmcenterprises/registry-creds
7
7
sources :
8
8
- https://github.com/upmc-enterprises/registry-creds
Original file line number Diff line number Diff line change @@ -47,7 +47,7 @@ helm install --name registry-creds --set dpr.enabled=true --set-string dpr.user=
47
47
48
48
#### From AWS
49
49
50
- Ensure your EC2 instances have the appropriate permissions as described in
50
+ Ensure your EC2 instances have the appropriate permissions as described in
51
51
[ registry-creds] ( https://github.com/upmc-enterprises/registry-creds ) documentation.
52
52
53
53
``` console
@@ -69,7 +69,7 @@ Create a `custom-values.yaml` file:
69
69
70
70
``` yaml
71
71
gcr :
72
- enabled : false
72
+ enabled : false
73
73
applicationDefaultCredentialsJson : |
74
74
{
75
75
" client_id " : " myID" ,
@@ -148,6 +148,11 @@ Parameter | Description | Default
148
148
` gcr.existingSecretName ` | defines an existing secret (in kube-system namespace) containing the credentials| ` "" `
149
149
` gcr.applicationDefaultCredentialsJson ` | JSON representing google cloud credentials. Only applicable if gcr.existingSecretName is empty | ` "" `
150
150
` gcr.url ` | URL for google container registry. Only applicable if gcr.existingSecretName is empty | ` "https://gcr.io" `
151
+ ` acr.enabled ` | enables the injection of azure container registry credentials | ` false `
152
+ ` acr.existingSecretName ` | defines an existing secret (in kube-system namespace) containing the credentials| ` "" `
153
+ ` acr.url ` | defines the url of azure container registry| Only applicable if acr.existingSecretName is empty | ` "" `
154
+ ` acr.clientId ` | is the client id used to access azure container registry | Only applicable if acr.existingSecretName is empty | ` "" `
155
+ ` acr.password ` | is the client password used to access azure container registry | Only applicable if acr.existingSecretName is empty | ` "" `
151
156
` rbac.enabled ` | enables the usage of RBAC for registry-creds (needed for clusters with RBAC enabled) | ` true `
152
157
` rbac.existingServiceAccountName ` | name of an existing service account to be used for RBAC permissions. If not defined a new service account will be created by the chart | ` "" `
153
158
` resources.limits ` .memory | memory resource limit | ` "100Mi" `
Original file line number Diff line number Diff line change @@ -3,4 +3,4 @@ registry-creds is now installed on your Kubernetes cluster
3
3
If everything is ok, you should see one or more secrets (depending on the enabled types) created on every existing
4
4
namespace (except for kube-system):
5
5
6
- kubectl get secret | egrep "(dpr|ecr|gcr)-secret"
6
+ kubectl get secret | egrep "(dpr|ecr|gcr|acr )-secret"
Original file line number Diff line number Diff line change 89
89
name : {{ default (include "registry-creds.name" . | printf "%s-dpr") .Values.dpr.existingSecretName }}
90
90
key : DOCKER_PRIVATE_REGISTRY_USER
91
91
{{- end }}
92
+ {{- if .Values.acr.enabled }}
93
+ - name : ACR_URL
94
+ valueFrom :
95
+ secretKeyRef :
96
+ name : {{ default (include "registry-creds.name" . | printf "%s-acr") .Values.acr.existingSecretName }}
97
+ key : ACR_URL
98
+ - name : ACR_CLIENT_ID
99
+ valueFrom :
100
+ secretKeyRef :
101
+ name : {{ default (include "registry-creds.name" . | printf "%s-acr") .Values.acr.existingSecretName }}
102
+ key : ACR_CLIENT_ID
103
+ - name : ACR_PASSWORD
104
+ valueFrom :
105
+ secretKeyRef :
106
+ name : {{ default (include "registry-creds.name" . | printf "%s-acr") .Values.acr.existingSecretName }}
107
+ key : ACR_PASSWORD
108
+ {{- end }}
92
109
{{- if .Values.gcr.enabled }}
93
110
volumeMounts :
94
111
- name : {{ template "registry-creds.name" . }}-gcr
Original file line number Diff line number Diff line change 27
27
- get
28
28
- update
29
29
---
30
- apiVersion : rbac.authorization.k8s.io/v1beta1
30
+ apiVersion : rbac.authorization.k8s.io/v1
31
31
kind : ClusterRoleBinding
32
32
metadata :
33
33
name : {{ template "registry-creds.name" . }}
@@ -45,4 +45,4 @@ kind: ServiceAccount
45
45
metadata :
46
46
name : {{ template "registry-creds.name" . }}
47
47
namespace : kube-system
48
- {{- end }}
48
+ {{- end }}
Original file line number Diff line number Diff line change
1
+ {{- if and .Values.acr.enabled (not .Values.acr.existingSecretName) }}
2
+ apiVersion : v1
3
+ kind : Secret
4
+ metadata :
5
+ name : {{ template "registry-creds.name" . }}-acr
6
+ namespace : kube-system
7
+ labels :
8
+ app : registry-creds
9
+ cloud : acr
10
+ data :
11
+ ACR_URL : {{ .Values.acr.url | b64enc | quote }}
12
+ ACR_CLIENT_ID : {{ .Values.acr.clientId | b64enc | quote }}
13
+ ACR_PASSWORD : {{ .Values.acr.password | b64enc | quote }}
14
+ type : Opaque
15
+ {{- end }}
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ replicaCount: 1
2
2
3
3
image :
4
4
name : " upmcenterprises/registry-creds"
5
- tag : " 1.9 "
5
+ tag : " 1.10 "
6
6
pullPolicy : " IfNotPresent"
7
7
8
8
nameOverride : " "
51
51
# gcr.url is the URL for google container registry. Only applicable if gcr.existingSecretName is empty
52
52
url : " https://gcr.io"
53
53
54
+ acr :
55
+ # acr.enabled enables the injection of azure container registry credentials
56
+ enabled : false
57
+ # acr.existingSecretName defines an existing secret (in kube-system namespace) containing the credentials
58
+ existingSecretName : " "
59
+ # acr.url defines the url of azure container registry. Only applicable if acr.existingSecretName is empty
60
+ url : " "
61
+ # acr.clientId is the client id used to access azure container registry. Only applicable if acr.existingSecretName is empty
62
+ clientId : " "
63
+ # acr.password is the client password used to access azure container registry. Only applicable if acr.existingSecretName is empty
64
+ password : " "
65
+
54
66
rbac :
55
67
# rbac.enabled enables the usage of RBAC for registry-creds
56
68
enabled : true
Original file line number Diff line number Diff line change
1
+ # Set to true for GPG signing
2
+ sign : false
3
+ # UID of the GPG key to use
4
+ key : Chart Releaser Test Key
Original file line number Diff line number Diff line change
1
+ # See https://github.com/helm/chart-testing#configuration
2
+ remote : origin
3
+ chart-dirs :
4
+ - charts
5
+ chart-repos :
6
+ - bitnami=https://charts.bitnami.com/bitnami
7
+ helm-extra-args : --timeout 600s
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments