summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author=Corey Hulen <corey@hulen.com>2016-01-05 20:35:36 -0600
committer=Corey Hulen <corey@hulen.com>2016-01-05 20:35:36 -0600
commit01a5f67398e0fa32f739534feba75d4c3a904c3e (patch)
tree04d2ae2c00b84a0473ee98323327bf6f5ce6b05a
parent7f8cb30bd36a88307148612f4b27d6a28f954b6b (diff)
downloadchat-01a5f67398e0fa32f739534feba75d4c3a904c3e.tar.gz
chat-01a5f67398e0fa32f739534feba75d4c3a904c3e.tar.bz2
chat-01a5f67398e0fa32f739534feba75d4c3a904c3e.zip
PLT-1607 adding more debugging info for email and push notifications
-rw-r--r--config/config.json31
-rw-r--r--utils/mail.go4
2 files changed, 31 insertions, 4 deletions
diff --git a/config/config.json b/config/config.json
index 5469608f8..fff45b9e6 100644
--- a/config/config.json
+++ b/config/config.json
@@ -54,7 +54,11 @@
"AmazonS3AccessKeyId": "",
"AmazonS3SecretAccessKey": "",
"AmazonS3Bucket": "",
- "AmazonS3Region": ""
+ "AmazonS3Region": "",
+ "AmazonS3Endpoint": "",
+ "AmazonS3BucketEndpoint": "",
+ "AmazonS3LocationConstraint": false,
+ "AmazonS3LowercaseBucket": false
},
"EmailSettings": {
"EnableSignUpWithEmail": true,
@@ -99,5 +103,28 @@
"AuthEndpoint": "",
"TokenEndpoint": "",
"UserApiEndpoint": ""
+ },
+ "GoogleSettings": {
+ "Enable": false,
+ "Secret": "",
+ "Id": "",
+ "Scope": "",
+ "AuthEndpoint": "",
+ "TokenEndpoint": "",
+ "UserApiEndpoint": ""
+ },
+ "LdapSettings": {
+ "Enable": false,
+ "LdapServer": null,
+ "LdapPort": 389,
+ "BaseDN": null,
+ "BindUsername": null,
+ "BindPassword": null,
+ "FirstNameAttribute": null,
+ "LastNameAttribute": null,
+ "EmailAttribute": null,
+ "UsernameAttribute": null,
+ "IdAttribute": null,
+ "QueryTimeout": 60
}
-}
+} \ No newline at end of file
diff --git a/utils/mail.go b/utils/mail.go
index ece4105a6..6625060de 100644
--- a/utils/mail.go
+++ b/utils/mail.go
@@ -98,12 +98,12 @@ func SendMail(to, subject, body string) *model.AppError {
}
func SendMailUsingConfig(to, subject, body string, config *model.Config) *model.AppError {
- l4g.Debug("sending mail to " + to + " with subject of '" + subject + "'")
-
if !config.EmailSettings.SendEmailNotifications || len(config.EmailSettings.SMTPServer) == 0 {
return nil
}
+ l4g.Debug("sending mail to " + to + " with subject of '" + subject + "'")
+
fromMail := mail.Address{config.EmailSettings.FeedbackName, config.EmailSettings.FeedbackEmail}
toMail := mail.Address{"", to}