mirror of
https://github.com/rustfs/rustfs.git
synced 2026-08-11 23:56:53 +00:00
feat: add support for external/existing certificate issuer (#2631)
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
{{- if .Values.mtls.enabled }}
|
||||
{{- if and .Values.mtls.enabled (not .Values.mtls.existingIssuerRef.enabled) }}
|
||||
apiVersion: cert-manager.io/v1
|
||||
kind: ClusterIssuer
|
||||
metadata:
|
||||
@@ -6,3 +6,4 @@ metadata:
|
||||
spec:
|
||||
selfSigned: {}
|
||||
{{- end }}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{{- if .Values.mtls.enabled }}
|
||||
{{- if and .Values.mtls.enabled (not .Values.mtls.existingIssuerRef.enabled) }}
|
||||
apiVersion: cert-manager.io/v1
|
||||
kind: Certificate
|
||||
metadata:
|
||||
@@ -11,4 +11,5 @@ spec:
|
||||
issuerRef:
|
||||
name: {{ include "rustfs.fullname" . }}-selfsigned-issuer
|
||||
kind: ClusterIssuer
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{{- if .Values.mtls.enabled }}
|
||||
{{- if and .Values.mtls.enabled (not .Values.mtls.existingIssuerRef.enabled) }}
|
||||
apiVersion: cert-manager.io/v1
|
||||
kind: Issuer
|
||||
metadata:
|
||||
@@ -7,4 +7,5 @@ metadata:
|
||||
spec:
|
||||
ca:
|
||||
secretName: {{ include "rustfs.fullname" . }}-root-ca-secret
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
|
||||
@@ -6,9 +6,16 @@ metadata:
|
||||
namespace: {{ .Release.Namespace }}
|
||||
spec:
|
||||
secretName: {{ include "rustfs.fullname" . }}-server-tls
|
||||
{{- if .Values.mtls.existingIssuerRef.enabled }}
|
||||
issuerRef:
|
||||
name: {{ .Values.mtls.existingIssuerRef.name }}
|
||||
kind: {{ .Values.mtls.existingIssuerRef.kind }}
|
||||
group: {{ .Values.mtls.existingIssuerRef.group }}
|
||||
{{- else }}
|
||||
issuerRef:
|
||||
name: {{ include "rustfs.fullname" . }}-ca-issuer
|
||||
kind: Issuer
|
||||
{{- end }}
|
||||
commonName: {{ include "rustfs.fullname" . }}-cluster
|
||||
dnsNames:
|
||||
- "*.{{ include "rustfs.fullname" . }}-headless"
|
||||
@@ -20,4 +27,4 @@ spec:
|
||||
{{- end }}
|
||||
usages:
|
||||
- server auth
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
@@ -6,10 +6,18 @@ metadata:
|
||||
namespace: {{ .Release.Namespace }}
|
||||
spec:
|
||||
secretName: {{ include "rustfs.fullname" . }}-client-tls
|
||||
{{- if .Values.mtls.existingIssuerRef.enabled }}
|
||||
issuerRef:
|
||||
name: {{ .Values.mtls.existingIssuerRef.name }}
|
||||
kind: {{ .Values.mtls.existingIssuerRef.kind }}
|
||||
group: {{ .Values.mtls.existingIssuerRef.group }}
|
||||
{{- else }}
|
||||
issuerRef:
|
||||
name: {{ include "rustfs.fullname" . }}-ca-issuer
|
||||
kind: Issuer
|
||||
{{- end }}
|
||||
commonName: {{ include "rustfs.fullname" . }}-cluster
|
||||
usages:
|
||||
- client auth
|
||||
{{- end }}
|
||||
|
||||
|
||||
@@ -230,6 +230,11 @@ mtls:
|
||||
enabled: false
|
||||
clientCertPath: "/opt/tls/client_cert.pem"
|
||||
clientKeyPath: "/opt/tls/client_key.pem"
|
||||
existingIssuerRef:
|
||||
enabled: false
|
||||
name: ""
|
||||
kind: ""
|
||||
group: ""
|
||||
|
||||
resources: {}
|
||||
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||
|
||||
Reference in New Issue
Block a user