Skip to content

Commit

Permalink
fix: own tls cert and issuer
Browse files Browse the repository at this point in the history
  • Loading branch information
akurilov committed Dec 12, 2024
1 parent 1e6806c commit 59b0a2b
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 0 deletions.
1 change: 1 addition & 0 deletions helm/webapp/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ metadata:
{{- include "webapp.labels" . | nindent 4 }}
annotations:
kubernetes.io/ingress.class: nginx
cert-manager.io/issuer: "{{ .Values.cert.issuer.name }}-webapp"
nginx.ingress.kubernetes.io/use-regex: "true"
nginx.ingress.kubernetes.io/ssl-redirect: "true"
nginx.ingress.kubernetes.io/force-ssl-redirect: "true"
Expand Down
15 changes: 15 additions & 0 deletions helm/webapp/templates/issuer-letsencrypt.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{{- $fullName := include "reader.fullname" . -}}
apiVersion: cert-manager.io/v1
kind: Issuer
metadata:
name: "{{ .Values.cert.issuer.name }}-webapp"
spec:
acme:
server: {{ .Values.cert.acme.server }}
email: {{ .Values.cert.acme.email }}
privateKeySecretRef:
name: {{ .Values.cert.issuer.name }}
solvers:
- http01:
ingress:
name: "{{ $fullName }}"
6 changes: 6 additions & 0 deletions helm/webapp/values-demo-0.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,9 @@ ingress:
- secretName: secret-webapp-tls-server
hosts:
- awakari.com

cert:
acme:
server: "https://acme-v02.api.letsencrypt.org/directory"
issuer:
name: letsencrypt
7 changes: 7 additions & 0 deletions helm/webapp/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -74,3 +74,10 @@ nodeSelector: {}
tolerations: []

affinity: {}

cert:
acme:
email: "awakari@awakari.com"
server: "https://acme-staging-v02.api.letsencrypt.org/directory"
issuer:
name: letsencrypt-staging

0 comments on commit 59b0a2b

Please sign in to comment.