-
Notifications
You must be signed in to change notification settings - Fork 0
/
README.noformat
57 lines (40 loc) · 1.67 KB
/
README.noformat
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
httplus
Cross platform http/https C++ object web server
Rules
All html/css/etc files must be contained under ${root}/pub.
e.g. /var/www/pub/index.html
If the resource is a file, that is found, it is rendered.
Otherwise it is used as a key to check for generators.
Generator objects are stored and retrieved using a hash of the root directory path as the key.
File serving rules:
No file type = Text mode
File type is in config text field = text mode
else = binary mode
404 errors are currently handled by a generator with the key "404".
## Configure
httplus.yaml:
ssls: <DEFAULT HTTPS CYPHER LIST>
http:
- root: /var/www/global # no default, mandatory
host: localhost # no default, "_" considered global
port: 8888 # default 80
home: index # optional default page
- root: /var/www/global # no default, mandatory
port: 8888 # default 80
home: index # optional default page
https:
- root: /var/www/global # no default, mandatory
host: localhost # no default, mandatory
port: 443 # default 443
home: index # optional default page
crt: /path/to/site.crt # no default, mandatory
key: /path/to/site.key # no default, mandatory
chain: /path/to/chain.pem # no default, optional
ssls: <CYPHER LIST> # no default, optional
## Generation
See ./usr/html.hpp
Switches
Key _HTTPLUS_ACCEPT_GZIP_
Type bool
Default 0
Description Enables compression of response body when request header contains "Accept-Encoding" contains "gzip", requires zlib