bucket not hardcoded
This commit is contained in:
parent
024948b8ff
commit
1337f6ba63
@ -41,7 +41,7 @@ type Directory struct {
|
||||
Directorys []Directory `json:"directorys"`
|
||||
}
|
||||
|
||||
var bucketName = "dev"
|
||||
var bucketName string
|
||||
|
||||
// setupS3Client connect the s3Client
|
||||
func setupS3Client(config AppConfig) (*minio.Client, error) {
|
||||
@ -64,6 +64,8 @@ func setupS3Client(config AppConfig) (*minio.Client, error) {
|
||||
return nil, fmt.Errorf("Bucket '%s' does not exist", config.S3Bucket)
|
||||
}
|
||||
|
||||
bucketName = config.S3Bucket
|
||||
|
||||
return minioClient, nil
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user