Documentation
¶
Overview ¶
Package binding builds pgrator-owned workload binding resources.
Index ¶
- func ConfigSecretName(binding *v1.PostgresBinding) string
- func CreateConfigSecret(scheme *runtime.Scheme, b *v1.PostgresBinding, instance string, ...) (*corev1.Secret, error)
- func CreateDatabaseRole(scheme *runtime.Scheme, b *v1.PostgresBinding, instance string, ...) (*cnpgv1.DatabaseRole, error)
- func CreateEgressNetworkPolicy(scheme *runtime.Scheme, b *v1.PostgresBinding, instance string) (*networkingv1.NetworkPolicy, error)
- func CreateNetworkPolicy(scheme *runtime.Scheme, b *v1.PostgresBinding, instance string) (*networkingv1.NetworkPolicy, error)
- func DatabaseRoleName(b *v1.PostgresBinding, instance string, ...) string
- type CredentialMaterial
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConfigSecretName ¶
func ConfigSecretName(binding *v1.PostgresBinding) string
ConfigSecretName returns the stable connection Secret name for a binding.
func CreateConfigSecret ¶
func CreateConfigSecret(scheme *runtime.Scheme, b *v1.PostgresBinding, instance string, caCertificate []byte, credentials map[v1.PostgresBindingCredential]CredentialMaterial) (*corev1.Secret, error)
CreateConfigSecret creates the complete stable workload-facing snapshot for an active instance. Callers must supply only validated material.
func CreateDatabaseRole ¶
func CreateDatabaseRole(scheme *runtime.Scheme, b *v1.PostgresBinding, instance string, credential v1.PostgresBindingCredential) (*cnpgv1.DatabaseRole, error)
func CreateEgressNetworkPolicy ¶
func CreateEgressNetworkPolicy(scheme *runtime.Scheme, b *v1.PostgresBinding, instance string) (*networkingv1.NetworkPolicy, error)
func CreateNetworkPolicy ¶
func CreateNetworkPolicy(scheme *runtime.Scheme, b *v1.PostgresBinding, instance string) (*networkingv1.NetworkPolicy, error)
func DatabaseRoleName ¶
func DatabaseRoleName(b *v1.PostgresBinding, instance string, credential v1.PostgresBindingCredential) string
DatabaseRoleName is unique for a binding, credential and physical instance. The suffix leaves room for CNPG's -client-cert Secret suffix.
Types ¶
type CredentialMaterial ¶
CredentialMaterial is the certificate and private key CNPG issued for one binding credential.
Click to show internal directories.
Click to hide internal directories.