mirror of
https://github.com/atareao/self-hosted.git
synced 2024-07-06 14:02:16 +02:00
26 lines
519 B
Plaintext
26 lines
519 B
Plaintext
server {
|
|
listen 80;
|
|
server_name localhost;
|
|
|
|
root /var/www/html;
|
|
index index.php;
|
|
|
|
access_log /var/log/nginx/wp-access.log;
|
|
error_log /var/log/nginx/wp-error.log;
|
|
|
|
location / {
|
|
try_files $uri $uri/ /index.php?$args;
|
|
}
|
|
|
|
location ~ \.php$ {
|
|
try_files $uri =404;
|
|
fastcgi_split_path_info ^(.+\.php)(/.+)$;
|
|
fastcgi_pass wp:9000;
|
|
include /etc/nginx/fastcgi.conf;
|
|
}
|
|
|
|
location ~* .(jpg|jpeg|png|gif|ico|css|js)$ {
|
|
expires 365d;
|
|
}
|
|
}
|