2014-09-07 21:51:34 +02:00
|
|
|
|
|
|
|
# try for WordPress index.php in /
|
|
|
|
# fall back to index.php + args (passed to php5-fpm later)
|
2014-11-06 22:41:07 +01:00
|
|
|
# also serves static files from the disk instead of passing to interpreter,
|
2014-09-07 21:51:34 +02:00
|
|
|
location / {
|
|
|
|
try_files $uri $uri/ /index.php?$args;
|
|
|
|
}
|
|
|
|
|
2014-10-10 10:05:42 +02:00
|
|
|
location ~* \.(?:ico|css|js|gif|jpe?g|png)$ {
|
2014-11-06 22:29:53 +01:00
|
|
|
add_header Cache-Control "public, max-age=604800";
|
2014-10-10 10:05:42 +02:00
|
|
|
}
|
|
|
|
|
2014-09-07 21:51:34 +02:00
|
|
|
# Add trailing slash to */wp-admin requests.
|
|
|
|
rewrite /wp-admin$ $scheme://$host$uri/ permanent;
|
|
|
|
|