You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

41 lines
1.6 KiB

  1. {{- if and .Values.global.enableSecurity (not .Values.certificates.externalCertificates.enabled)}}
  2. apiVersion: cert-manager.io/v1{{ if .Values.global.certificates.alphacrds }}alpha1{{ end }}
  3. kind: Certificate
  4. metadata:
  5. name: {{ template "seaweedfs.name" . }}-volume-cert
  6. namespace: {{ .Release.Namespace }}
  7. labels:
  8. app.kubernetes.io/name: {{ template "seaweedfs.name" . }}
  9. helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
  10. app.kubernetes.io/managed-by: {{ .Release.Service }}
  11. app.kubernetes.io/instance: {{ .Release.Name }}
  12. app.kubernetes.io/component: volume
  13. spec:
  14. secretName: {{ template "seaweedfs.name" . }}-volume-cert
  15. issuerRef:
  16. name: {{ template "seaweedfs.name" . }}-ca-issuer
  17. kind: Issuer
  18. commonName: {{ .Values.certificates.commonName }}
  19. subject:
  20. organizations:
  21. - "SeaweedFS CA"
  22. dnsNames:
  23. - '*.{{ .Release.Namespace }}'
  24. - '*.{{ .Release.Namespace }}.svc'
  25. - '*.{{ .Release.Namespace }}.svc.cluster.local'
  26. - '*.{{ template "seaweedfs.name" . }}-master'
  27. - '*.{{ template "seaweedfs.name" . }}-master.{{ .Release.Namespace }}'
  28. - '*.{{ template "seaweedfs.name" . }}-master.{{ .Release.Namespace }}.svc'
  29. - '*.{{ template "seaweedfs.name" . }}-master.{{ .Release.Namespace }}.svc.cluster.local'
  30. {{- if .Values.certificates.ipAddresses }}
  31. ipAddresses:
  32. {{- range .Values.certificates.ipAddresses }}
  33. - {{ . }}
  34. {{- end }}
  35. {{- end }}
  36. privateKey:
  37. algorithm: {{ .Values.certificates.keyAlgorithm }}
  38. size: {{ .Values.certificates.keySize }}
  39. duration: {{ .Values.certificates.duration }}
  40. renewBefore: {{ .Values.certificates.renewBefore }}
  41. {{- end }}