File tree 21 files changed +147
-1
lines changed
21 files changed +147
-1
lines changed Original file line number Diff line number Diff line change 2
2
3
3
# output of hack/ci/validate-helm-resources.sh
4
4
* -templated.yaml
5
+
6
+ # remove local development nix configs
7
+ * .nix
8
+ * .lock
Original file line number Diff line number Diff line change 1
1
{ {- define " name" -} }{ { .Release.Name } }{ {- end } }
2
2
{ {- define " agentname" -} }{ { .Values.agentName | default .Release.Name } }{ {- end } }
3
+
4
+ { {- define " imagePullSecrets" -} }
5
+ { {- range .Values.global.imagePullSecrets } }
6
+ { {- if eq (typeOf .) " map[string]interface {}" } }
7
+ - { { toYaml . | trim } }
8
+ { {- else } }
9
+ - name: { { . } }
10
+ { {- end } }
11
+ { {- end } }
12
+ { {- end -} }
Original file line number Diff line number Diff line change 24
24
app.kubernetes.io/instance : ' {{ template "agentname" . }}'
25
25
app.kubernetes.io/version : ' {{ .Values.image.tag | default .Chart.AppVersion }}'
26
26
spec :
27
+ {{- if .Values.global.imagePullSecrets }}
28
+ imagePullSecrets :
29
+ {{- include "imagePullSecrets" . | trim | nindent 8 }}
30
+ {{- end }}
27
31
containers :
28
32
- name : agent
29
33
args :
Original file line number Diff line number Diff line change
1
+ global :
2
+ # # Reference to one or more secrets to be used when pulling images
3
+ # # ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
4
+ # #
5
+ imagePullSecrets : []
6
+ # - name: "image-pull-secret"
7
+ # or
8
+ # - "image-pull-secret"
1
9
# Required: the name of the APIExport in kcp that this Sync Agent is supposed to serve.
2
10
apiExportName : " "
3
11
Original file line number Diff line number Diff line change 19
19
{ {- end -} }
20
20
{ {- end -} }
21
21
22
+ { {- define " kcp.imagePullSecrets" -} }
23
+ { {- range .Values.global.imagePullSecrets } }
24
+ { {- if eq (typeOf .) " map[string]interface {}" } }
25
+ - { { toYaml . | trim } }
26
+ { {- else } }
27
+ - name: { { . } }
28
+ { {- end } }
29
+ { {- end } }
30
+ { {- end -} }
31
+
22
32
{ {- define " certificates.kcp" -} }
23
33
{ {- if not (eq .Values.certificates.name " " ) -} }
24
34
{ {- $trimmedName := printf " %s" .Values.certificates.name | trunc 58 | trimSuffix " -" -} }
Original file line number Diff line number Diff line change 47
47
hostAliases :
48
48
{{- toYaml .Values.cache.hostAliases.values | nindent 6 }}
49
49
{{- end }}
50
+ {{- if .Values.global.imagePullSecrets }}
51
+ imagePullSecrets :
52
+ {{- include "kcp.imagePullSecrets" . | trim | nindent 8 }}
53
+ {{- end }}
50
54
containers :
51
55
- name : cache
52
56
image : {{ .Values.cache.image }}:{{- include "cache.version" . }}
Original file line number Diff line number Diff line change
1
+ global :
2
+ # # Reference to one or more secrets to be used when pulling images
3
+ # # ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
4
+ # #
5
+ imagePullSecrets : []
6
+ # - name: "image-pull-secret"
7
+ # or
8
+ # - "image-pull-secret"
1
9
externalHostname : " "
2
10
cache :
3
11
enabled : true
Original file line number Diff line number Diff line change @@ -5,6 +5,19 @@ Expand the name of the chart.
5
5
{ {- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix " -" } }
6
6
{ {- end } }
7
7
8
+ { {/*
9
+ Define imagePullSecrets for the chart.
10
+ */} }
11
+ { {- define " kcp-operator.imagePullSecrets" -} }
12
+ { {- range .Values.global.imagePullSecrets } }
13
+ { {- if eq (typeOf .) " map[string]interface {}" } }
14
+ - { { toYaml . | trim } }
15
+ { {- else } }
16
+ - name: { { . } }
17
+ { {- end } }
18
+ { {- end } }
19
+ { {- end -} }
20
+
8
21
{ {/*
9
22
Create a default fully qualified app name.
10
23
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
Original file line number Diff line number Diff line change 30
30
serviceAccountName : {{ include "kcp-operator.serviceAccountName" . }}
31
31
securityContext :
32
32
{{- toYaml .Values.podSecurityContext | nindent 8 }}
33
+ {{- if .Values.global.imagePullSecrets }}
34
+ imagePullSecrets :
35
+ {{- include "kcp-operator.imagePullSecrets" . | trim | nindent 8 }}
36
+ {{- end }}
33
37
containers :
34
38
- name : {{ .Chart.Name }}
35
39
securityContext :
Original file line number Diff line number Diff line change 1
1
# Default values for kcp-operator.
2
2
# Declare variables to be passed into your templates.
3
-
3
+ global :
4
+ # # Reference to one or more secrets to be used when pulling images
5
+ # # ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
6
+ # #
7
+ imagePullSecrets : []
8
+ # - name: "image-pull-secret"
9
+ # or
10
+ # - "image-pull-secret"
4
11
# This is to override the chart name.
5
12
nameOverride : " "
6
13
fullnameOverride : " "
Original file line number Diff line number Diff line change @@ -35,6 +35,16 @@ v{{- .Chart.AppVersion -}}
35
35
{ {- $batteries | uniq | join " ," -} }
36
36
{ {- end -} }
37
37
38
+ { {- define " kcp.imagePullSecrets" -} }
39
+ { {- range .Values.global.imagePullSecrets } }
40
+ { {- if eq (typeOf .) " map[string]interface {}" } }
41
+ - { { toYaml . | trim } }
42
+ { {- else } }
43
+ - name: { { . } }
44
+ { {- end } }
45
+ { {- end } }
46
+ { {- end -} }
47
+
38
48
{ {- define " frontproxy.fullname" -} }
39
49
{ {- $trimmedName := printf " %s" (include " kcp.fullname" .) | trunc 52 | trimSuffix " -" -} }
40
50
{ {- printf " %s-front-proxy" $trimmedName | trunc 63 | trimSuffix " -" -} }
Original file line number Diff line number Diff line change 48
48
tolerations :
49
49
{{- toYaml . | nindent 8 }}
50
50
{{- end }}
51
+ {{- if .Values.global.imagePullSecrets }}
52
+ imagePullSecrets :
53
+ {{- include "kcp.imagePullSecrets" . | trim | nindent 8 }}
54
+ {{- end }}
51
55
containers :
52
56
- name : etcd
53
57
image : {{ .Values.etcd.image }}:{{ .Values.etcd.tag }}
Original file line number Diff line number Diff line change 66
66
tolerations :
67
67
{{- toYaml . | nindent 8 }}
68
68
{{- end }}
69
+ {{- if .Values.global.imagePullSecrets }}
70
+ imagePullSecrets :
71
+ {{- include "kcp.imagePullSecrets" . | trim | nindent 8 }}
72
+ {{- end }}
69
73
containers :
70
74
- name : kcp-front-proxy
71
75
image : " {{ .Values.kcpFrontProxy.image }}:{{- include " frontproxy.version" . }}"
Original file line number Diff line number Diff line change @@ -106,6 +106,10 @@ spec:
106
106
tolerations :
107
107
{{- toYaml . | nindent 8 }}
108
108
{{- end }}
109
+ {{- if .Values.global.imagePullSecrets }}
110
+ imagePullSecrets :
111
+ {{- include "kcp.imagePullSecrets" . | trim | nindent 8 }}
112
+ {{- end }}
109
113
containers :
110
114
- name : kcp
111
115
image : {{ .Values.kcp.image }}:{{- include "kcp.version" . }}
Original file line number Diff line number Diff line change
1
+ global :
2
+ # # Reference to one or more secrets to be used when pulling images
3
+ # # ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
4
+ # #
5
+ imagePullSecrets : []
6
+ # - name: "image-pull-secret"
7
+ # or
8
+ # - "image-pull-secret"
1
9
externalHostname : " "
2
10
externalPort : " " # defaults to 8443 for .Values.kcpFrontProxy.service.type "LoadBalancer", 443 otherwise.
3
11
etcd :
Original file line number Diff line number Diff line change 19
19
{ {- end -} }
20
20
{ {- end -} }
21
21
22
+ { {- define " kcp.imagePullSecrets" -} }
23
+ { {- range .Values.global.imagePullSecrets } }
24
+ { {- if eq (typeOf .) " map[string]interface {}" } }
25
+ - { { toYaml . | trim } }
26
+ { {- else } }
27
+ - name: { { . } }
28
+ { {- end } }
29
+ { {- end } }
30
+ { {- end -} }
31
+
22
32
{ {- define " certificates.kcp" -} }
23
33
{ {- if not (eq .Values.certificates.name " " ) -} }
24
34
{ {- $trimmedName := printf " %s" .Values.certificates.name | trunc 58 | trimSuffix " -" -} }
Original file line number Diff line number Diff line change 72
72
hostAliases :
73
73
{{- toYaml .Values.kcpFrontProxy.hostAliases.values | nindent 6 }}
74
74
{{- end }}
75
+ {{- if .Values.global.imagePullSecrets }}
76
+ imagePullSecrets :
77
+ {{- include "kcp.imagePullSecrets" . | trim | nindent 8 }}
78
+ {{- end }}
75
79
containers :
76
80
- name : kcp-front-proxy
77
81
image : " {{ .Values.kcpFrontProxy.image }}:{{- include " frontproxy.version" . }}"
Original file line number Diff line number Diff line change
1
+ global :
2
+ # # Reference to one or more secrets to be used when pulling images
3
+ # # ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
4
+ # #
5
+ imagePullSecrets : []
6
+ # - name: "image-pull-secret"
7
+ # or
8
+ # - "image-pull-secret"
1
9
externalHostname : " "
2
10
kcpFrontProxy :
3
11
enabled : true
Original file line number Diff line number Diff line change 19
19
{ {- end -} }
20
20
{ {- end -} }
21
21
22
+ { {- define " kcp.imagePullSecrets" -} }
23
+ { {- range .Values.global.imagePullSecrets } }
24
+ { {- if eq (typeOf .) " map[string]interface {}" } }
25
+ - { { toYaml . | trim } }
26
+ { {- else } }
27
+ - name: { { . } }
28
+ { {- end } }
29
+ { {- end } }
30
+ { {- end -} }
31
+
22
32
{ {- define " certificates.kcp" -} }
23
33
{ {- if not (eq .Values.certificates.name " " ) -} }
24
34
{ {- $trimmedName := printf " %s" .Values.certificates.name | trunc 58 | trimSuffix " -" -} }
Original file line number Diff line number Diff line change @@ -108,6 +108,10 @@ spec:
108
108
hostAliases :
109
109
{{- toYaml .Values.kcp.hostAliases.values | nindent 6 }}
110
110
{{- end }}
111
+ {{- if .Values.global.imagePullSecrets }}
112
+ imagePullSecrets :
113
+ {{- include "kcp.imagePullSecrets" . | trim | nindent 8 }}
114
+ {{- end }}
111
115
containers :
112
116
- name : kcp
113
117
image : {{ .Values.kcp.image }}:{{- include "kcp.version" . }}
Original file line number Diff line number Diff line change
1
+ global :
2
+ # # Reference to one or more secrets to be used when pulling images
3
+ # # ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
4
+ # #
5
+ imagePullSecrets : []
6
+ # - name: "image-pull-secret"
7
+ # or
8
+ # - "image-pull-secret"externalHostname: ""
1
9
externalHostname : " "
2
10
etcd :
3
11
enabled : true
You can’t perform that action at this time.
0 commit comments