-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathfull_test.conf
More file actions
93 lines (77 loc) · 1.96 KB
/
full_test.conf
File metadata and controls
93 lines (77 loc) · 1.96 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
# -----------------------------------------------------------------
# Full configuration file for testing parser and validation
# -----------------------------------------------------------------
server {
listen 8080;
server_name localhost;
root www/full_test;
upload_path uploads;
# Default error pages
error_page 400 www/errors/400.html;
error_page 403 www/errors/403.html;
error_page 404 www/errors/404.html;
error_page 405 www/errors/405.html;
error_page 413 www/errors/413.html;
error_page 500 www/errors/500.html;
# Maximum allowed body size in bytes
client_max_body_size 100000000;
# Index files to look for
index full_test.html;
# CGI configuration
cgi_path /usr/bin/php-cgi;
cgi_extension .php;
# ---------------------------------
# Locations
# ---------------------------------
location / {
root www/full_test;
index full_test.html;
upload_path uploads/main;
methods GET;
}
location /calculator {
root www/full_test;
index calculator.html;
methods GET;
}
location /calculate-cgi {
root www/cgi;
index calculator.py;
cgi_path /usr/bin/python3;
cgi_extension .py;
methods GET POST;
}
location /gallery {
root www/cgi;
index lister.py;
cgi_path /usr/bin/python3;
cgi_extension .py;
methods GET;
}
location /upload {
root www/full_test;
index upload.html;
methods GET;
}
location /uploads {
root www;
upload_path uploads;
methods GET POST DELETE;
}
location /cgi-bin {
root www/cgi;
upload_path uploads/cgi;
cgi_path /usr/bin/python3;
cgi_extension .py;
methods GET POST;
}
location /old-page {
return 301 /;
}
location /redirect-upload {
return 302 /upload;
}
location /redirect-calculator {
return 307 /calculator;
}
}