mirror of
https://github.com/pgsty/minio.git
synced 2026-07-19 20:20:25 +03:00
Certificate and key must both be specified or empty together
This commit is contained in:
@@ -40,6 +40,9 @@ func main() {
|
|||||||
log.Println(address)
|
log.Println(address)
|
||||||
certFile := c.String("cert")
|
certFile := c.String("cert")
|
||||||
keyFile := c.String("key")
|
keyFile := c.String("key")
|
||||||
|
if (certFile != "" && keyFile == "") || (certFile == "" && keyFile != "") {
|
||||||
|
log.Fatal("Both certificate and key must be provided to enable https")
|
||||||
|
}
|
||||||
tls := (certFile != "" && keyFile != "")
|
tls := (certFile != "" && keyFile != "")
|
||||||
storageType := getStorageType(storageTypeStr)
|
storageType := getStorageType(storageTypeStr)
|
||||||
serverConfig := server.ServerConfig{
|
serverConfig := server.ServerConfig{
|
||||||
|
|||||||
Reference in New Issue
Block a user