forked from bolt/bolt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.nginx.conf
95 lines (73 loc) · 2.05 KB
/
.travis.nginx.conf
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
worker_processes 1;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
gzip on;
server {
listen 8123;
root %ROOTDIR%;
index index.php;
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location ~* /thumbs/(.*)$ {
try_files $uri $uri/ /index.php?$query_string;
}
location ~* /async/(.*)$ {
try_files $uri $uri/ /index.php?$query_string;
}
location /app/classes/upload {
try_files $uri $uri/ /app/classes/upload/index.php?$query_string;
}
# If you set a custom branding path, you will need to change '/bolt/' here to match
location ~* /bolt/(.*)$ {
try_files $uri $uri/ /index.php?$query_string;
}
location ~* \.(?:ico|css|js|gif|jpe?g|png|ttf|woff|woff2)$ {
access_log off;
expires 30d;
add_header Pragma public;
add_header Cache-Control "public, mustrevalidate, proxy-revalidate";
}
location = /robots.txt {
access_log off;
log_not_found off;
}
location = /favicon.ico {
access_log off;
log_not_found off;
}
location ~ \.php$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_script_name;
fastcgi_param HTTPS off;
}
location ~ /\.ht {
deny all;
}
location /app {
deny all;
}
location ~ /vendor {
deny all;
}
location ~ \.db$ {
deny all;
}
location ~ \.yml$ {
deny all;
}
location ~ \.twig$ {
deny all;
}
location ~ \.md$ {
deny all;
}
}
}