mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-08-28 10:54:59 +00:00
requirements when auth is enabled
postgres binding is turned off TLS must be turned on
This commit is contained in:
parent
2847c22a4c
commit
be66103c45
1 changed files with 9 additions and 0 deletions
|
|
@ -541,6 +541,15 @@ func (m *Command) SetupServer() error {
|
|||
if err != nil {
|
||||
return errors.Wrap(err, "instantiating authN object")
|
||||
}
|
||||
|
||||
// disable postgres binding if auth is enabled
|
||||
m.Config.Postgres.Bind = ""
|
||||
|
||||
// TLS must be enabled if auth is
|
||||
if m.Config.TLS.CertificatePath == "" || m.Config.TLS.CertificateKeyPath == "" || m.Config.TLS.CACertPath == "" {
|
||||
return fmt.Errorf("transport layer security (TLS) is not configured properly. TLS is required when AuthN/Z is enabled, current configuration: %v", m.Config.TLS)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
m.Handler, err = http.NewHandler(
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue