Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions modules/setting/storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ type MinioStorageConfig struct {
ChecksumAlgorithm string `ini:"MINIO_CHECKSUM_ALGORITHM" json:",omitempty"`
ServeDirect bool `ini:"SERVE_DIRECT"`
BucketLookUpType string `ini:"MINIO_BUCKET_LOOKUP_TYPE" json:",omitempty"`
SkipVersionCheck bool `ini:"SKIP_VERSION_CHECK" json:",omitempty"`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this PR!

Could you add a minio prefix to this setting, as well add documentation to the app.example.ini file?

}

func (cfg *MinioStorageConfig) ToShadow() {
Expand Down
4 changes: 3 additions & 1 deletion modules/storage/minio.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,9 @@ func NewMinioStorage(ctx context.Context, cfg *setting.Storage) (ObjectStorage,
// Otherwise even if the request itself fails (403, 404, etc), the code should still continue because the parameters seem "good" enough.
// Keep in mind that GetBucketVersioning requires "owner" to really succeed, so it can't be used to check the existence.
// Not using "BucketExists (HeadBucket)" because it doesn't include detailed failure reasons.
err = getBucketVersioning(ctx, minioClient, config.Bucket)
if !config.SkipVersionCheck {
err = getBucketVersioning(ctx, minioClient, config.Bucket)
}
if err != nil {
errResp, ok := err.(minio.ErrorResponse)
if !ok {
Expand Down
Loading