diff --git a/internal/config/config.go b/internal/config/config.go index 958926975..e2bfd0b68 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -98,7 +98,7 @@ func loadFromFile(path string) (*Config, error) { return nil, fmt.Errorf("could not read file at path %s: %s", path, err) } - config := &Config{} + config := Empty() if err := yaml.Unmarshal(bytes, config); err != nil { return nil, fmt.Errorf("could not unmarshal file at path %s: %s", path, err) } diff --git a/internal/db/pg/pg.go b/internal/db/pg/pg.go index 5301f0410..31312b61e 100644 --- a/internal/db/pg/pg.go +++ b/internal/db/pg/pg.go @@ -148,6 +148,7 @@ func derivePGOptions(c *config.Config) (*pg.Options, error) { case config.DBTLSModeRequire: tlsConfig = &tls.Config{ InsecureSkipVerify: false, + ServerName: c.DBConfig.Address, } }