Creating custom roles for users

Description:

Hi,

We’ve got an idea to create a read-only, write/update and schema (superuser). The latter is quite easy and supported however I don’t see exactly how I should go about creating the other 2 roles in the Operator.

The read-only user should have select only access on the created database and the write/update users can make update statements etc. but cannot update the schema.

Is something like this possible with the current operator?

Version:

Postgresql Operator 2.2

Expected Result:

[What the user expected to see or happen before the issue occurred]

Hi @Arnout_Hoebreckx , do you have a list of ROLEs for each user?

I would think that it should be possible with init.sql: Bootstrap PostgreSQL on Kubernetes

Where you can bootstrap the cluster and execute arbitary SQL (like create roles).

Then you can reference them in the users section: Application and system users - Percona Operator for PostgreSQL