Skip to content

Can we configure s3 bucket per pg cluster? #1209

Closed
@raja-gola

Description

@raja-gola

Can we configure s3 bucket per pg cluster?

Currently the s3 bucket for WAL_S3_BUCKET and LOGICAL_BACKUP_S3_BUCKET come from operator config.

if c.OpConfig.WALES3Bucket != "" {
		envVars = append(envVars, v1.EnvVar{Name: "WAL_S3_BUCKET", Value: c.OpConfig.WALES3Bucket})
		envVars = append(envVars, v1.EnvVar{Name: "WAL_BUCKET_SCOPE_SUFFIX", Value: getBucketScopeSuffix(string(uid))})
		envVars = append(envVars, v1.EnvVar{Name: "WAL_BUCKET_SCOPE_PREFIX", Value: ""})
}
               { 
			Name:  "LOGICAL_BACKUP_S3_BUCKET",
			Value: c.OpConfig.LogicalBackup.LogicalBackupS3Bucket,
		},

We need to configure bucket per cluster. I tried to define them in pod_environment_configmap but looks like operator config takes precedence.

        // add vars taken from pod_environment_configmap and pod_environment_secret first
	// (to allow them to override the globals set in the operator config)
	if len(customPodEnvVarsList) > 0 {
		envVars = append(envVars, customPodEnvVarsList...)
	}

Is there anyway we could configure s3 bucket per cluster and overwrite s3 bucket defined in operator config??

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions