update s3 endpoint handling

virtual host extracts bucket name from endpoint environment variable;
path uses fixed bucket name
This commit is contained in:
Michael Hohn
2025-05-13 10:47:54 -07:00
committed by =Michael Hohn
parent bde8ac2db7
commit 5bdbd60cc5
5 changed files with 62 additions and 9 deletions

View File

@@ -16,6 +16,7 @@ func CreateMinIOBucketIfNotExists(client *minio.Client, bucketName string) error
}
if !exists {
// if env.Get("MRVA_S3_PATHSTYLE") == "true" {}
slog.Info("Creating bucket", "name", bucketName)
err = client.MakeBucket(ctx, bucketName, minio.MakeBucketOptions{})
if err != nil {