31 lines
628 B
Plaintext
31 lines
628 B
Plaintext
server {
|
|
listen 80;
|
|
server_name default;
|
|
|
|
root /var/www/html;
|
|
index index.html;
|
|
|
|
client_max_body_size 5m;
|
|
client_body_timeout 60;
|
|
|
|
location / {
|
|
try_files $uri $uri/ /index.html;
|
|
|
|
if (!-e $request_filename) {
|
|
rewrite ^/(.*)$ /index.html last;
|
|
}
|
|
}
|
|
|
|
location ~ \.php$ {
|
|
include fastcgi_params;
|
|
fastcgi_pass unix:/run/php/php-fpm.sock;
|
|
fastcgi_param SCRIPT_FILENAME $request_filename;
|
|
}
|
|
|
|
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ {
|
|
try_files $uri /index.html;
|
|
expires max;
|
|
log_not_found off;
|
|
}
|
|
}
|