Merge pull request #14 from devanlai/fix-auth-enable-from-config
Fix auth modes enabled by config file
This commit is contained in:
commit
97c080dc59
8
main.go
8
main.go
|
@ -65,8 +65,12 @@ func main() {
|
|||
|
||||
utils.ApplyFlags(cliFlags, flagMappings, c, appOptions, backendOptions)
|
||||
|
||||
appOptions.EnableBasicAuth = c.IsSet("credential")
|
||||
appOptions.EnableTLSClientAuth = c.IsSet("tls-ca-crt")
|
||||
if c.IsSet("credential") {
|
||||
appOptions.EnableBasicAuth = true
|
||||
}
|
||||
if c.IsSet("tls-ca-crt") {
|
||||
appOptions.EnableTLSClientAuth = true
|
||||
}
|
||||
|
||||
err = appOptions.Validate()
|
||||
if err != nil {
|
||||
|
|
Loading…
Reference in New Issue