Skip to content

Commit

Permalink
Add logging for new mongo options
Browse files Browse the repository at this point in the history
  • Loading branch information
coldfire84 committed Jan 17, 2020
1 parent 1b27996 commit 07e5cab
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions backends/mongo.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ func NewMongo(authOpts map[string]string, logLevel log.Level) (Mongo, error) {

if saltEncoding, ok := authOpts["salt_encoding"]; ok {
m.SaltEncoding = saltEncoding
log.Infof("Mongo set salt encoding to: %s", saltEncoding)
} else {
m.SaltEncoding = "base64"
}
Expand Down Expand Up @@ -106,6 +107,7 @@ func NewMongo(authOpts map[string]string, logLevel log.Level) (Mongo, error) {

if m.Username != "" && m.Password != "" {
if m.AuthSource != "" {
log.Infof("Mongo set AuthSource to: %s", m.AuthSource)
opts.Auth = &options.Credential{
AuthSource: m.AuthSource,
Username: m.Username,
Expand Down

0 comments on commit 07e5cab

Please sign in to comment.