Skip to content

Commit 442878b

Browse files
committed
Allow users to set ssl_groups or ssl_ecdh_curve via spec.config.parameters.
1 parent af258f2 commit 442878b

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

config/crd/bases/postgres-operator.crunchydata.com_postgresclusters.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4822,7 +4822,8 @@ spec:
48224822
- message: change port using .spec.port instead
48234823
rule: '!has(self.port)'
48244824
- message: TLS is always enabled
4825-
rule: '!has(self.ssl) && !self.exists(k, k.startsWith("ssl_"))'
4825+
rule: '!has(self.ssl) && !self.exists(k, k.startsWith("ssl_")
4826+
&& !(k == ''ssl_groups'' || k == ''ssl_ecdh_curve''))'
48264827
- message: domain socket paths cannot be changed
48274828
rule: '!self.exists(k, k.startsWith("unix_socket_"))'
48284829
- message: wal_level must be "replica" or higher

pkg/apis/postgres-operator.crunchydata.com/v1beta1/postgres_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ type PostgresConfigSpec struct {
5454
//
5555
// +kubebuilder:validation:XValidation:rule=`!has(self.listen_addresses)`,message=`network connectivity is always enabled: listen_addresses`
5656
// +kubebuilder:validation:XValidation:rule=`!has(self.port)`,message=`change port using .spec.port instead`
57-
// +kubebuilder:validation:XValidation:rule=`!has(self.ssl) && !self.exists(k, k.startsWith("ssl_"))`,message=`TLS is always enabled`
57+
// +kubebuilder:validation:XValidation:rule=`!has(self.ssl) && !self.exists(k, k.startsWith("ssl_") && !(k == 'ssl_groups' || k == 'ssl_ecdh_curve'))`,message=`TLS is always enabled`
5858
// +kubebuilder:validation:XValidation:rule=`!self.exists(k, k.startsWith("unix_socket_"))`,message=`domain socket paths cannot be changed`
5959
//
6060
// # Write Ahead Log

0 commit comments

Comments
 (0)