-
Notifications
You must be signed in to change notification settings - Fork 101
/
Copy pathwordpress-4.conf
66 lines (52 loc) · 1.15 KB
/
wordpress-4.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
root /home/u1/domains/example.com;
location ~ /\. {
deny all;
}
location = /favicon.ico {
log_not_found off;
access_log off;
}
location = /robots.txt {
allow all;
log_not_found off;
access_log off;
}
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location ~ ^/wp-admin/includes/ {
deny all;
}
location ~* /wp-includes/js/tinymce/wp-tinymce.php {
allow all;
include fastcgi.conf;
fastcgi_intercept_errors on;
fastcgi_pass unix:/var/run/php5-example.com.sock;
}
location ~* /wp-includes/.*\.(php|php3|php4|php5|php6|phps|phtml)$ {
deny all;
}
location ~* /wp-content/.*\.(php|php3|php4|php5|php6|phps|phtml)$ {
deny all;
}
location ~* /modules/.*\.(php|php3|php4|php5|php6|phps|phtml)$ {
deny all;
}
location ~* /skins/.*\.(php|php3|php4|php5|php6|phps|phtml)$ {
deny all;
}
location = /xmlrpc.php {
deny all;
}
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ {
expires max;
log_not_found off;
}
location ~* /(?:uploads|files)/.*\.(php|php3|php4|php5|php6|phps|phtml)$ {
deny all;
}
location ~ \.php$ {
include fastcgi.conf;
fastcgi_intercept_errors on;
fastcgi_pass unix:/var/run/php5-example.com.sock;
}