Documentation ¶
Index ¶
- Constants
- func Cache(ctx context.Context, kube client.Client, mg resource.Managed, ...) (sc *corev1.Secret, err error)
- func DeleteCache(ctx context.Context, kube client.Client, mg resource.Managed) (err error)
- func GenerateRestoreDBInstanceFromS3Input(name, password string, p *v1alpha1.DBInstanceParameters) *svcsdk.RestoreDBInstanceFromS3Input
- func GenerateRestoreDBInstanceFromSnapshotInput(name string, p *v1alpha1.DBInstanceParameters) *svcsdk.RestoreDBInstanceFromDBSnapshotInput
- func GenerateRestoreDBInstanceToPointInTimeInput(name string, p *v1alpha1.DBInstanceParameters) *svcsdk.RestoreDBInstanceToPointInTimeInput
- func GetDesiredPassword(ctx context.Context, kube client.Client, cr svcapitypes.RDSClusterOrInstance) (desiredPassword string, err error)
- func GetSecretValue(ctx context.Context, kube client.Client, ref *xpv1.SecretKeySelector) (val string, err error)
- func PasswordUpToDate(ctx context.Context, kube client.Client, cr svcapitypes.RDSClusterOrInstance) (upToDate bool, err error)
Constants ¶
View Source
const ( PasswordCacheKey = "dbMasterUserPassword" RestoreFlagCacheKay = "dbRestoreState" RestoreStateRestored restoreSate = "RestoreStateRestored" RestoreStateNormal restoreSate = "RestoreStateNormal" ErrNoRetrievePasswordOrGenerate = "cannot retrieve password form masterUserPasswordSecretRef or generate a password" ErrNoMasterUserPasswordSecretRefNorAutogenerateNoRestore = "neither a masterUserPasswordSecretRef is given, nor password autogeneration was enabled, not a restore is performed" ErrCachePassword = "cannot cache password" ErrNoPasswordUpToDate = "cannot determine password up to date status" ErrGetCachedPassword = "cannot get cached password" ErrRetrievePasswordForUpdate = "cannot retrieve password for update" )
Publicly usable variables
Variables ¶
This section is empty.
Functions ¶
func Cache ¶ added in v0.42.0
func Cache(ctx context.Context, kube client.Client, mg resource.Managed, kv map[string]string) (sc *corev1.Secret, err error)
Cache caches the given key/value map to the corresponding cache secret
func DeleteCache ¶ added in v0.42.0
DeleteCache removes the (secret) cache
func GenerateRestoreDBInstanceFromS3Input ¶
func GenerateRestoreDBInstanceFromS3Input(name, password string, p *v1alpha1.DBInstanceParameters) *svcsdk.RestoreDBInstanceFromS3Input
GenerateRestoreDBInstanceFromS3Input from RDSInstanceSpec
func GenerateRestoreDBInstanceFromSnapshotInput ¶
func GenerateRestoreDBInstanceFromSnapshotInput(name string, p *v1alpha1.DBInstanceParameters) *svcsdk.RestoreDBInstanceFromDBSnapshotInput
GenerateRestoreDBInstanceFromSnapshotInput from RDSInstanceSpec
func GenerateRestoreDBInstanceToPointInTimeInput ¶
func GenerateRestoreDBInstanceToPointInTimeInput(name string, p *v1alpha1.DBInstanceParameters) *svcsdk.RestoreDBInstanceToPointInTimeInput
GenerateRestoreDBInstanceToPointInTimeInput from RDSInstanceSpec
func GetDesiredPassword ¶ added in v0.42.0
func GetDesiredPassword(ctx context.Context, kube client.Client, cr svcapitypes.RDSClusterOrInstance) (desiredPassword string, err error)
GetDesiredPassword calculates the desired password from cache/masterPasswordSecretRef
func GetSecretValue ¶ added in v0.42.0
func GetSecretValue(ctx context.Context, kube client.Client, ref *xpv1.SecretKeySelector) (val string, err error)
GetSecretValue fetches the referenced input secret key reference
func PasswordUpToDate ¶ added in v0.42.0
func PasswordUpToDate(ctx context.Context, kube client.Client, cr svcapitypes.RDSClusterOrInstance) (upToDate bool, err error)
PasswordUpToDate tell whether the password is up-to-date (depends on restore, masterPasswordSecretRef and cached password)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.