postgresql-operator

API Reference

Packages

postgresql.facets.cloud/v1alpha1

Package v1alpha1 contains API Schema definitions for the postgresql v1alpha1 API group

Resource Types

Grant

Grant is the Schema for the grants API

Field Description
apiVersion string postgresql.facets.cloud/v1alpha1
kind string Grant
metadata ObjectMeta Refer to Kubernetes API documentation for fields of metadata.
spec GrantSpec  

GrantSpec

GrantSpec defines the desired state of Grant

Appears in:

Field Description
roleRef ResourceReference Defines the role reference to grant permissions
privileges string array Defines the list of permissions to grant for a role
database string Defines the Database to grant permission for a role
schema string Defines the Schema to grant permission for a role
table string Defines the Database to grant permission for a role

Role

Role is the Schema for the roles API

Field Description
apiVersion string postgresql.facets.cloud/v1alpha1
kind string Role
metadata ObjectMeta Refer to Kubernetes API documentation for fields of metadata.
spec RoleSpec  

RolePrivilege

RolePrivilege is the PostgreSQL identifier to add or remove a permission on a role. See https://www.postgresql.org/docs/current/sql-createrole.html for available privileges.

Appears in:

Field Description
superUser boolean SuperUser grants SUPERUSER privilege when true.
createDb boolean CreateDb grants CREATEDB when true, allowing the role to create databases.
createRole boolean CreateRole grants CREATEROLE when true, allowing this role to create other roles.
login boolean Login grants LOGIN when true, allowing the role to login to the server.
inherit boolean Inherit grants INHERIT when true, allowing the role to inherit permissions from other roles it is a member of.
replication boolean Replication grants REPLICATION when true, allowing the role to connect in replication mode.
bypassRls boolean BypassRls grants BYPASSRLS when true, allowing the role to bypass row-level security policies.

RoleSpec

RoleSpec defines the desired state of Role

Appears in:

Field Description
connectSecretRef ResourceReference ConnectSecretRef references the secret that contains database details () used to create this role.
passwordSecretRef SecretKeySelector PasswordSecretRef references the secret that contains the password used for this role.
connectionLimit integer ConnectionLimit to be applied to the role.
privileges RolePrivilege Privileges to be granted.

ResourceReference

The Database Connection details secret selector

Appears in:

Field Description
name The name of secret that contains PostgreSQL database details username, password, endpoint, port and database
namespace The namespace of the secret

SecretKeySelector

The Role password secret selector

Appears in:

Field Description
ResourceReference Includes resource reference
key The key name in the secret to get role password