-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathmain.me
More file actions
207 lines (171 loc) · 5.71 KB
/
main.me
File metadata and controls
207 lines (171 loc) · 5.71 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
/*
main.me -- Main MakeMe File for Appweb
*/
Me.load({
makeme: '>=1.0.0',
plugins: [ 'installs' ],
blend: [
'src/**.me',
'certs/**.me',
'?doc/doc.me',
'?samples/samples.me',
'?installs/installs.me',
'?local.me',
],
modules: [ 'installs/service.es' ],
configure: {
requires: [ 'osdep', 'http', 'mpr', 'pcre'],
discovers: [ 'ssl', 'watchdog', 'esp', 'mdb' ],
extras: [ 'cgi', 'dir', 'ejs', 'fast', 'php', 'proxy', 'sqlite' ],
},
customize: [
/*
The optional custom.me file is loaded after main.me is fully processed. It can
thus override any setting. Feel free to create and customize.
*/
'custom.me',
],
settings: {
/*
Set compat to true to enable compatibility defines to assist migrating pre Appweb 8 handlers/modules
*/
compat: true,
/*
Set to true to emit warnings about deprecated APIs
*/
deprecatedWarnings: false,
integrate: true,
/*
Installation prefix set
*/
prefixes: 'install-prefixes',
manifest: 'installs/manifest.me',
/*
Name and path of the appweb config file. Defaults to './appweb.conf' if empty.
*/
configFile: 'appweb.conf',
/*
Local main program code to include in appweb.c. Typically put in local.me.
localMain: '/path/main.c',
*/
/* Must build locally to build tools */
platforms: [ 'local' ],
certs: {
gendh: true
},
compiler: {
fortify: false,
},
esp: {
cmd: true,
name: 'appweb-esp',
legacy: false,
module: false,
},
http: {
basic: true,
cache: true,
cmd: true,
defense: true,
digest: true,
dir: true,
http2: true,
pam: true,
sendfile: true,
upload: true,
webSockets: true,
},
mbedtls: {
compact: true, /* Compact edition - Disable non-essential ciphers and features */
},
openssl: {
version: '1.0', /* Base edition */
},
mpr: {
alloc: {
// quota: 204800, /* Amount of memory to allocate before a GC */
// cache: 0, /* Amount of memory to buffer for quick allocations */
// check: false, /* Memory allocation debug and stats (slow) */
},
/*
Enable logging via mprLog to the log file
The default is to enable logging for both debug and release builds.
*/
logging: true, /* Enable application logging */
oslog: false, /* Write to the O/S log file */
romMount: "/rom", /* Virtual mount point for a rom file system */
ssl: {
cache: 512, /* Set the session cache size (items) */
logLevel: 6, /* Starting logging level for SSL messages */
handshakes: 3, /* Set maximum number of renegotiations (zero means infinite) */
ticket: true, /* Enable session resumption via ticketing - client side session caching */
timeout: 86400, /* Session and ticketing duration in seconds */
},
threadStack: 0, /* Use the default system stack size */
threadLimitByCores: true, /* Limit number of active threads to CPU core count */
},
/*
Build without a file system (from ROM)
*/
rom: false,
watchdog: {
name: 'appman',
},
/*
Tailor the optimization for size|balanced|speed
*/
tune: 'size',
/*
Initial home directory for the server
*/
serverRoot: '.',
},
usage: {
'configFile': 'Path of the appweb.conf file',
'mpr.logging': 'Enable application logging (true|false)',
'serverRoot': 'Home directory for the server ',
},
targets: {
cgi: {
configurable: true,
description: 'Common Gateway Interface Module',
path: 'src/modules/cgiHandler.c',
depends: [ 'libmod_cgi' ],
},
dir: {
configurable: true,
description: 'Directory Listing Module',
},
fast: {
configurable: true,
description: 'FastCGI Module',
path: 'src/modules/fastHandler.c',
depends: [ 'libmod_fast' ],
},
proxy: {
configurable: true,
description: 'Proxy Module',
path: 'src/modules/proxyHandler.c',
depends: [ 'libmod_proxy' ],
},
projects: {
action: `
genProjects('--with esp --with mdb --with cgi --with proxy', 'default', ['freebsd-arm', 'linux-x64', 'macosx-arm64', 'vxworks-arm', 'windows-x64'])
`,
},
publish: {
action: `publish()`,
},
mine: {
action: `
genProjects('--with openssl --with cgi --with esp --with proxy', 'mine', ['macosx-arm64'])
`,
},
format: {
shell: `uncrustify -q -c .uncrustify --replace --no-backup src/*.{c,h} src/modules/*.c src/utils/*.c`
},
},
usage: {
'rom': 'Build without a file system (true|false)',
}
})