Set defualt value of AWS_REGION
This commit is contained in:
parent
294a4eb054
commit
d3439db85b
3 changed files with 2 additions and 5 deletions
|
|
@ -26,7 +26,7 @@ Here are the descriptions of values available to use in the `settings` table:
|
||||||
| AWS_SES_ID | | Amazon Web Services - Simple Email Service - access id |
|
| AWS_SES_ID | | Amazon Web Services - Simple Email Service - access id |
|
||||||
| AWS_SES_SECRET | | Amazon Web Services - Simple Email Service - access secret |
|
| AWS_SES_SECRET | | Amazon Web Services - Simple Email Service - access secret |
|
||||||
| AWS_SES_EMAIL_FROM | | Amazon Web Services - Simple Email Service - email from field |
|
| AWS_SES_EMAIL_FROM | | Amazon Web Services - Simple Email Service - email from field |
|
||||||
| AWS_REGION | | Amazon Web Services - Account region |
|
| AWS_REGION | us-east-1 | Amazon Web Services - Account region |
|
||||||
| EMAIL_MAX_TXS | | maximum number of transactions to include in the email body |
|
| EMAIL_MAX_TXS | | maximum number of transactions to include in the email body |
|
||||||
| FUNCTION_LNDHUB | DISABLE | system level switch for using LNDHUB in place of LND |
|
| FUNCTION_LNDHUB | DISABLE | system level switch for using LNDHUB in place of LND |
|
||||||
| LNDHUB_URL | | URL for the LNDHUB service |
|
| LNDHUB_URL | | URL for the LNDHUB service |
|
||||||
|
|
|
||||||
|
|
@ -93,9 +93,6 @@ func Send_email(recipient string, subject string, htmlBody string, textBody stri
|
||||||
aws_ses_secret := db.Get_setting("AWS_SES_SECRET")
|
aws_ses_secret := db.Get_setting("AWS_SES_SECRET")
|
||||||
sender := db.Get_setting("AWS_SES_EMAIL_FROM")
|
sender := db.Get_setting("AWS_SES_EMAIL_FROM")
|
||||||
region := db.Get_setting("AWS_REGION")
|
region := db.Get_setting("AWS_REGION")
|
||||||
if region == "" {
|
|
||||||
region = "us-east-1"
|
|
||||||
}
|
|
||||||
|
|
||||||
sess, err := session.NewSession(&aws.Config{
|
sess, err := session.NewSession(&aws.Config{
|
||||||
Region: aws.String(region),
|
Region: aws.String(region),
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,7 @@ INSERT INTO settings (name, value) VALUES ('FUNCTION_EMAIL', '');
|
||||||
INSERT INTO settings (name, value) VALUES ('AWS_SES_ID', '');
|
INSERT INTO settings (name, value) VALUES ('AWS_SES_ID', '');
|
||||||
INSERT INTO settings (name, value) VALUES ('AWS_SES_SECRET', '');
|
INSERT INTO settings (name, value) VALUES ('AWS_SES_SECRET', '');
|
||||||
INSERT INTO settings (name, value) VALUES ('AWS_SES_EMAIL_FROM', '');
|
INSERT INTO settings (name, value) VALUES ('AWS_SES_EMAIL_FROM', '');
|
||||||
INSERT INTO settings (name, value) VALUES ('AWS_REGION', '');
|
INSERT INTO settings (name, value) VALUES ('AWS_REGION', 'us-east-1');
|
||||||
INSERT INTO settings (name, value) VALUES ('EMAIL_MAX_TXS', '');
|
INSERT INTO settings (name, value) VALUES ('EMAIL_MAX_TXS', '');
|
||||||
INSERT INTO settings (name, value) VALUES ('FUNCTION_LNDHUB', '');
|
INSERT INTO settings (name, value) VALUES ('FUNCTION_LNDHUB', '');
|
||||||
INSERT INTO settings (name, value) VALUES ('LNDHUB_URL', '');
|
INSERT INTO settings (name, value) VALUES ('LNDHUB_URL', '');
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue