ungleich-k8s/apps/nginx-certbot-helm/templates/certbot-job.yaml
2021-06-19 20:01:52 +02:00

30 lines
796 B
YAML

---
apiVersion: batch/v1
kind: Job
metadata:
name: {{ .Release.Name }}-getcert
spec:
template:
metadata:
labels:
app: {{ .Release.Name }}-tls1-nginx
spec:
restartPolicy: Never
containers:
- name: certbot
image: ungleich/ungleich-certbot
ports:
- containerPort: 80
env:
- name: DOMAIN
value: "{{ .Values.serviceName }}.{{ .Release.Namespace }}.svc.{{ .Values.clusterDomain }}"
- name: EMAIL
value: "{{ .Values.email }}"
volumeMounts:
- name: etcletsencrypt
mountPath: "/etc/letsencrypt"
volumes:
- name: etcletsencrypt
persistentVolumeClaim:
claimName: {{ .Release.Name }}-letsencrypt-certs
backoffLimit: 3