@@ -467,7 +467,7 @@ func getTenantCreatedResponse(session *models.Principal, params admin_api.Create
467
467
}
468
468
469
469
isEncryptionAvailable := false
470
- if * tenantReq .EnableTLS {
470
+ if tenantReq . EnableTLS != nil && * tenantReq .EnableTLS {
471
471
// If user request autoCert, Operator will generate certificate keypair for MinIO (server), Console (server) and KES (server and app mTLS)
472
472
isEncryptionAvailable = true
473
473
minInst .Spec .RequestAutoCert = * tenantReq .EnableTLS
@@ -536,8 +536,10 @@ func getTenantCreatedResponse(session *models.Principal, params admin_api.Create
536
536
var consoleAccess string
537
537
var consoleSecret string
538
538
539
- //enableConsole := true
540
- enableConsole := * tenantReq .EnableConsole
539
+ enableConsole := true
540
+ if tenantReq .EnableConsole != nil && * tenantReq .EnableConsole {
541
+ enableConsole = * tenantReq .EnableConsole
542
+ }
541
543
542
544
if enableConsole {
543
545
consoleSelector := fmt .Sprintf ("%s-console" , * tenantReq .Name )
@@ -597,7 +599,7 @@ func getTenantCreatedResponse(session *models.Principal, params admin_api.Create
597
599
},
598
600
}
599
601
600
- if ! minInst .Spec .RequestAutoCert && tenantReq .TLS .Console != nil {
602
+ if ! minInst .Spec .RequestAutoCert && tenantReq .TLS != nil && tenantReq . TLS .Console != nil {
601
603
consoleExternalTLSCertificateSecretName := fmt .Sprintf ("%s-console-external-certificates" , secretName )
602
604
tlsCrt , err := base64 .StdEncoding .DecodeString (* tenantReq .TLS .Console .Crt )
603
605
if err != nil {
0 commit comments