zalando / postgres-operator

Postgres operator creates and manages PostgreSQL clusters running in Kubernetes
https://postgres-operator.readthedocs.io/
MIT License
4.37k stars 980 forks source link

`allowedSourceRanges` should support ipv6 #2787

Open viceice opened 1 month ago

viceice commented 1 month ago

Please, answer some short questions which should help us to understand your problem / question better?

I've a cluster which supports dualstack networking and i like to allow ipv6 access to my postgresql clusters.

To get this working i need to set ipv6 ranges to allowedSourceRanges to the postgresql crd.

it should also be possible to set the ipFamilyPolicy and ipFamilies fields on the service opbjects.

Workaround: Create my own service

Error:

postgresql/db/pgc1 dry-run failed (Invalid): postgresql.acid.zalan.do "pgc1" is invalid: [spec.allowedSourceRanges[1]: Invalid value: "fd01::/48": spec.allowedSourceRanges[1] in body should match '^(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]).(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]).(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]).(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])/(\d|[1-2]\d|3[0-2])
\(']