github.com/minio/minio@v0.0.0-20240328213742-3f72439b8a27/cmd/config-versions.go (about) 1 // Copyright (c) 2015-2021 MinIO, Inc. 2 // 3 // This file is part of MinIO Object Storage stack 4 // 5 // This program is free software: you can redistribute it and/or modify 6 // it under the terms of the GNU Affero General Public License as published by 7 // the Free Software Foundation, either version 3 of the License, or 8 // (at your option) any later version. 9 // 10 // This program is distributed in the hope that it will be useful 11 // but WITHOUT ANY WARRANTY; without even the implied warranty of 12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 // GNU Affero General Public License for more details. 14 // 15 // You should have received a copy of the GNU Affero General Public License 16 // along with this program. If not, see <http://www.gnu.org/licenses/>. 17 18 package cmd 19 20 import ( 21 "github.com/minio/minio/internal/auth" 22 "github.com/minio/minio/internal/config" 23 "github.com/minio/minio/internal/config/compress" 24 xldap "github.com/minio/minio/internal/config/identity/ldap" 25 "github.com/minio/minio/internal/config/identity/openid" 26 "github.com/minio/minio/internal/config/notify" 27 "github.com/minio/minio/internal/config/policy/opa" 28 "github.com/minio/minio/internal/config/storageclass" 29 "github.com/minio/minio/internal/logger" 30 "github.com/minio/pkg/v2/quick" 31 ) 32 33 // FileLogger is introduced to workaround the dependency about logrus 34 type FileLogger struct { 35 Enable bool `json:"enable"` 36 Filename string `json:"filename"` 37 } 38 39 // ConsoleLogger is introduced to workaround the dependency about logrus 40 type ConsoleLogger struct { 41 Enable bool `json:"enable"` 42 } 43 44 // serverConfigV33 is just like version '32', removes clientID from NATS and MQTT, and adds queueDir, queueLimit in all notification targets. 45 type serverConfigV33 struct { 46 quick.Config `json:"-"` // ignore interfaces 47 48 Version string `json:"version"` 49 50 // S3 API configuration. 51 Credential auth.Credentials `json:"credential"` 52 Region string `json:"region"` 53 Worm config.BoolFlag `json:"worm"` 54 55 // Storage class configuration 56 StorageClass storageclass.Config `json:"storageclass"` 57 58 // Notification queue configuration. 59 Notify notify.Config `json:"notify"` 60 61 // Logger configuration 62 Logger logger.Config `json:"logger"` 63 64 // Compression configuration 65 Compression compress.Config `json:"compress"` 66 67 // OpenID configuration 68 OpenID openid.Config `json:"openid"` 69 70 // External policy enforcements. 71 Policy struct { 72 // OPA configuration. 73 OPA opa.Args `json:"opa"` 74 75 // Add new external policy enforcements here. 76 } `json:"policy"` 77 78 LDAPServerConfig xldap.LegacyConfig `json:"ldapserverconfig"` 79 }