You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
return"", fmt.Errorf(`Neither "%s" nor the pair "%s"/"%s" were present in the TLS secret`, tlsSecretPemName, tlsSecretCertName, tlsSecretKeyName)
137
+
}
138
+
ifcertKey=="" {
139
+
returnpem, nil
140
+
}
141
+
ifpem=="" {
142
+
returncertKey, nil
143
+
}
144
+
ifcertKey!=pem {
145
+
return"", fmt.Errorf(`If all of "%s", "%s" and "%s" are present in the secret, the entry for "%s" must be equal to the concatenation of "%s" with "%s"`, tlsSecretCertName, tlsSecretKeyName, tlsSecretPemName, tlsSecretPemName, tlsSecretCertName, tlsSecretKeyName)
146
+
}
147
+
returncertKey, nil
148
+
}
149
+
122
150
// ensureTLSSecret will create or update the operator-managed Secret containing
123
151
// the concatenated certificate and key from the user-provided Secret.
assert.Contains(t, err.Error(), `If all of "tls.crt", "tls.key" and "tls.pem" are present in the secret, the entry for "tls.pem" must be equal to the concatenation of "tls.crt" with "tls.key"`)
Copy file name to clipboardExpand all lines: docs/RELEASE_NOTES.md
+2-1
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,8 @@
4
4
5
5
- Changes
6
6
- MongoDB database of the statefulSet is managed using distinct Role, ServiceAccount and RoleBinding.
7
-
7
+
- TLS Secret can also contain a single "tls.pem" entry, containing the concatenation of the certificate and key
8
+
- If a TLS secret contains all of "tls.key", "tls.crt" and "tls.pem" entries, the operator will raise an error if the "tls.pem" one is not equal to the concatenation of "tls.crt" with "tls.key"
0 commit comments