-
Notifications
You must be signed in to change notification settings - Fork 0
/
php-stv.conf
31 lines (26 loc) · 905 Bytes
/
php-stv.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
server {
listen 8086;
server_name localhost;
root C:/Users/username/Documents/GitHub/php-stv/public;
index index.html index.php;
gzip on;
gzip_types text/css application/javascript image/svg+xml image/x-icon application/json;
location / {
# First attempt to serve request as file, then as directory, then fall back to displaying a 404.
try_files $uri $uri/ =404;
}
error_page 404 /404.php;
# cache static files and avoid logging them
location ~* .(ico|svg|jpg|png|js|css|woff)$ {
expires 1M;
access_log off;
}
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
location ~ \.php$ {
try_files $uri =404;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
}