Mercurial Hosting > nabble
annotate conf/Init.luan @ 49:219206026b57
create_sub_app fix
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Sun, 27 Jun 2021 14:44:56 -0600 |
parents | 72765b66e2c3 |
children | 6bd33547304f |
rev | line source |
---|---|
0 | 1 java() |
2 local Luan = require "luan:Luan.luan" | |
3 local error = Luan.error | |
2
abe0694e9849
replace local_dir with home_dir
Franklin Schmidt <fschmidt@gmail.com>
parents:
0
diff
changeset
|
4 local Io = require "luan:Io.luan" |
abe0694e9849
replace local_dir with home_dir
Franklin Schmidt <fschmidt@gmail.com>
parents:
0
diff
changeset
|
5 local uri = Io.uri or error() |
0 | 6 local MailHome = require "java:fschmidt.util.mail.MailHome" |
7 local System = require "java:java.lang.System" | |
8 local Logging = require "luan:logging/Logging.luan" | |
9 local logger = Logging.logger "Init_default" | |
42
af4632c42979
fix init conf to fix subscription emails
Vadim Filimonov <fffilimonov@yandex.ru>
parents:
18
diff
changeset
|
10 local pairs = Luan.pairs or error() |
0 | 11 |
12 local Init = {} | |
13 | |
42
af4632c42979
fix init conf to fix subscription emails
Vadim Filimonov <fffilimonov@yandex.ru>
parents:
18
diff
changeset
|
14 System.setProperty("mail.smtp.host", "mail.smtp2go.com") |
0 | 15 System.setProperty("mail.mime.base64.ignoreerrors", "true") |
16 System.setProperty("mail.mime.address.strict", "false") | |
17 System.setProperty("mail.mime.decodetext.strict", "false") | |
18 | |
19 Init.dbUrl = "jdbc:postgresql://localhost:5432/nabble" | |
20 Init.dbUser = "administrator" | |
21 Init.dbPassword = "" | |
22 | |
23 Init.poolSize = 130 | |
24 | |
2
abe0694e9849
replace local_dir with home_dir
Franklin Schmidt <fschmidt@gmail.com>
parents:
0
diff
changeset
|
25 Init.home_dir = uri( uri("classpath:nabble").to_string() ).parent().parent().to_string().."/" |
0 | 26 |
27 -- for now | |
28 local smtp = MailHome.getSmtpServer("mail.smtp2go.com","dev@singlesushi.com","FB4dating") | |
29 smtp.setPort(2525) | |
30 MailHome.setDefaultSmtpServer(smtp) | |
31 | |
32 Init.homeContextUrl = "http://me.nabble.com:8081" | |
33 | |
34 Init.deleteInactiveSites = false | |
35 Init.nabbleHost = "me.nabble.com:8080" | |
36 | |
37 | |
38 Init.defaultHost = "me.nabble.com:8080" | |
39 Init.domain = Init.defaultHost | |
40 Init.nabbleHost = Init.defaultHost | |
41 | |
42 | |
43 --local HashSet = require "java:java.util.HashSet" | |
44 --Init.sysadmins = HashSet.new {} -- list of emails | |
45 | |
46 --Init.monitor_emails = {} -- list of emails | |
47 | |
6 | 48 --Init.ssl_dir = nil |
49 | |
0 | 50 |
51 -- for serve_nabble.luan | |
52 | |
53 function Init.fix_serve(Serve) | |
54 if Serve.is_www then | |
55 Serve.is_forums = false | |
56 else | |
57 Serve.www_port = 8081 | |
58 Serve.is_www = true | |
59 end | |
60 end | |
61 | |
18 | 62 local Server = require "java:global.Server" |
63 Server.add("local","jdbc:postgresql://localhost:5432/nabble","administrator","","me.nabble.com"); | |
64 | |
0 | 65 function Init.add_filters(context) |
66 end | |
67 | |
68 | |
69 return Init |