Skip to content

Commit

Permalink
feat: modify for custom CA certificates (#486)
Browse files Browse the repository at this point in the history
  • Loading branch information
olevski authored Feb 7, 2022
1 parent bdd1c49 commit c6774a4
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 2 deletions.
4 changes: 4 additions & 0 deletions helm-chart/renku-gateway/requirements.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
dependencies:
- name: certificates
version: "0.0.1"
repository: "https://swissdatasciencecenter.github.io/helm-charts/"
4 changes: 2 additions & 2 deletions helm-chart/renku-gateway/templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ data:
traefik.toml: |
{{ if .Values.development }}
[log]
level = "debug"
level = "DEBUG"
{{ else }}
[log]
level = "error"
level = "ERROR"
{{ end }}
[api]
Expand Down
11 changes: 11 additions & 0 deletions helm-chart/renku-gateway/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ spec:
- name: config
configMap:
name: {{ template "gateway.fullname" . }}
{{- include "certificates.volumes" . | nindent 8 }}
initContainers:
{{- include "certificates.initContainer" . | nindent 8 }}
containers:
- name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
Expand All @@ -41,6 +44,7 @@ spec:
volumeMounts:
- mountPath: /config
name: config
{{- include "certificates.volumeMounts.system" . | nindent 12 }}
readinessProbe:
tcpSocket:
port: {{ .Values.service.port }}
Expand Down Expand Up @@ -94,6 +98,8 @@ spec:
release: {{ .Release.Name }}
{{ include "call-nested" (list . "redis" "redis.fullname") }}-client: "true"
spec:
initContainers:
{{- include "certificates.initContainer" . | nindent 8 }}
containers:
- name: {{ .Chart.Name }}
image: "{{ .Values.image.auth.repository }}:{{ .Values.image.auth.tag }}"
Expand Down Expand Up @@ -172,6 +178,9 @@ spec:
value: {{ .Values.sentry.dsn }}
- name: SENTRY_ENVIRONMENT
value: {{ .Values.sentry.environment }}
{{- include "certificates.env.python" . | nindent 12 }}
volumeMounts:
{{- include "certificates.volumeMounts.system" . | nindent 12 }}
livenessProbe:
httpGet:
path: /health
Expand Down Expand Up @@ -200,3 +209,5 @@ spec:
tolerations:
{{ toYaml . | indent 8 }}
{{- end }}
volumes:
{{- include "certificates.volumes" . | nindent 8 }}
12 changes: 12 additions & 0 deletions helm-chart/renku-gateway/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,18 @@ global:
keycloak:
## Explicitly set another realm than "renku" here
realm:

## Specify a secret that containes the certificate
## if you would like to use a custom CA. The key for the secret
## should have the .crt extension otherwise it is ignored. The
## keys across all secrets are mounted as files in one location so
## the keys across all secrets have to be unique.
certificates:
image:
repository: renku/certificates
tag: '0.0.1'
customCAs: []
# - secret:

replicaCount: 1

Expand Down

0 comments on commit c6774a4

Please sign in to comment.