diff options
Diffstat (limited to 'pkgs/webapps/peertube/sendmail.patch')
-rw-r--r-- | pkgs/webapps/peertube/sendmail.patch | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/pkgs/webapps/peertube/sendmail.patch b/pkgs/webapps/peertube/sendmail.patch index b42bc49..48c7d4d 100644 --- a/pkgs/webapps/peertube/sendmail.patch +++ b/pkgs/webapps/peertube/sendmail.patch | |||
@@ -1,14 +1,14 @@ | |||
1 | commit 677374d59c6aa2cb8145da3cd9c17fe05fd9b149 | 1 | commit 486964fad93334a52fb05e7d0497ecac3eb684fe |
2 | Author: Ismaël Bouya <ismael.bouya@normalesup.org> | 2 | Author: Ismaël Bouya <ismael.bouya@normalesup.org> |
3 | Date: Wed Feb 13 12:16:27 2019 +0100 | 3 | Date: Wed Feb 13 12:16:27 2019 +0100 |
4 | 4 | ||
5 | Add sendmail | 5 | Add sendmail |
6 | 6 | ||
7 | diff --git a/config/production.yaml.example b/config/production.yaml.example | 7 | diff --git a/config/production.yaml.example b/config/production.yaml.example |
8 | index bb5ac251..4583f1f5 100644 | 8 | index c56691bf4..8abdfb2a7 100644 |
9 | --- a/config/production.yaml.example | 9 | --- a/config/production.yaml.example |
10 | +++ b/config/production.yaml.example | 10 | +++ b/config/production.yaml.example |
11 | @@ -46,6 +46,8 @@ ldap: | 11 | @@ -66,6 +66,8 @@ auth: |
12 | 12 | ||
13 | # SMTP server to send emails | 13 | # SMTP server to send emails |
14 | smtp: | 14 | smtp: |
@@ -17,12 +17,12 @@ index bb5ac251..4583f1f5 100644 | |||
17 | hostname: null | 17 | hostname: null |
18 | port: 465 # If you use StartTLS: 587 | 18 | port: 465 # If you use StartTLS: 587 |
19 | username: null | 19 | username: null |
20 | diff --git a/server/initializers/constants.ts b/server/initializers/constants.ts | 20 | diff --git a/server/initializers/config.ts b/server/initializers/config.ts |
21 | index fb21df37..c551b4f9 100644 | 21 | index 45a667826..c1c15f05b 100644 |
22 | --- a/server/initializers/constants.ts | 22 | --- a/server/initializers/config.ts |
23 | +++ b/server/initializers/constants.ts | 23 | +++ b/server/initializers/config.ts |
24 | @@ -188,6 +188,8 @@ const CONFIG = { | 24 | @@ -50,6 +50,8 @@ const CONFIG = { |
25 | USER_FILTER: config.has('ldap.user_filter') ? config.get<string>('ldap.user_filter') : '(|(email=%username%)(uid=%username%))' | 25 | }, |
26 | }, | 26 | }, |
27 | SMTP: { | 27 | SMTP: { |
28 | + TRANSPORT: config.has('smtp.transport') ? config.get<string>('smtp.transport') : 'smtp', | 28 | + TRANSPORT: config.has('smtp.transport') ? config.get<string>('smtp.transport') : 'smtp', |
@@ -31,10 +31,10 @@ index fb21df37..c551b4f9 100644 | |||
31 | PORT: config.get<number>('smtp.port'), | 31 | PORT: config.get<number>('smtp.port'), |
32 | USERNAME: config.get<string>('smtp.username'), | 32 | USERNAME: config.get<string>('smtp.username'), |
33 | diff --git a/server/lib/emailer.ts b/server/lib/emailer.ts | 33 | diff --git a/server/lib/emailer.ts b/server/lib/emailer.ts |
34 | index f384a254..ec6e249b 100644 | 34 | index 7484524a4..512c5c068 100644 |
35 | --- a/server/lib/emailer.ts | 35 | --- a/server/lib/emailer.ts |
36 | +++ b/server/lib/emailer.ts | 36 | +++ b/server/lib/emailer.ts |
37 | @@ -27,33 +27,41 @@ class Emailer { | 37 | @@ -40,33 +40,41 @@ class Emailer { |
38 | this.initialized = true | 38 | this.initialized = true |
39 | 39 | ||
40 | if (Emailer.isEnabled()) { | 40 | if (Emailer.isEnabled()) { |
@@ -99,7 +99,7 @@ index f384a254..ec6e249b 100644 | |||
99 | } else { | 99 | } else { |
100 | if (!isTestInstance()) { | 100 | if (!isTestInstance()) { |
101 | logger.error('Cannot use SMTP server because of lack of configuration. PeerTube will not be able to send mails!') | 101 | logger.error('Cannot use SMTP server because of lack of configuration. PeerTube will not be able to send mails!') |
102 | @@ -62,11 +70,17 @@ class Emailer { | 102 | @@ -75,11 +83,17 @@ class Emailer { |
103 | } | 103 | } |
104 | 104 | ||
105 | static isEnabled () { | 105 | static isEnabled () { |