Skip to content

Commit

Permalink
Updated example .env file
Browse files Browse the repository at this point in the history
  • Loading branch information
tarteo committed Nov 26, 2024
1 parent 7f43a37 commit d6c49e9
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions internal/controller/bucket_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,18 +129,19 @@ func (r *BucketReconciler) getSecretData(secret *core.Secret, key string) (strin
}

func (r *BucketReconciler) getS3Client(ctx context.Context, bucket *s3v1.Bucket) (*s3.S3, error) {
var region string = os.Getenv("DEFAULT_S3_REGION")
if bucket.Spec.Region != "" {
region = bucket.Spec.Region
}

var (
region string = os.Getenv("DEFAULT_S3_REGION")
endpoint string = os.Getenv("DEFAULT_S3_ENDPOINT")
accessKey string = os.Getenv("DEFAULT_S3_ACCESS_KEY")
secretKey string = os.Getenv("DEFAULT_S3_SECRET_KEY")
validationError error
)

if bucket.Spec.Region != "" {
region = bucket.Spec.Region
}

if bucket.Spec.Secret != "" {
var secret core.Secret

Expand Down

0 comments on commit d6c49e9

Please sign in to comment.