Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # /etc/nginx/conf.d/linux-dash.conf
- server {
- server_name linux-dash.erictest;
- root /var/www/linux-dash;
- index index.html index.php;
- access_log /var/log/nginx/access.log;
- error_log /var/log/nginx/error.log;
- # Cache static files for as long as possible
- location ~* \.(?:xml|ogg|mp3|mp4|ogv|svg|svgz|eot|otf|woff|ttf|css|js|jpg|jpeg|gif|png|ico)$ {
- try_files $uri =404;
- expires max;
- access_log off;
- add_header Pragma public;
- add_header Cache-Control "public, must-revalidate, proxy-revalidate";
- }
- # if hosting in a sub folder, setup a new location
- # replace `/linus-dash` with the folder name eg. `/folder_name`
- #location /linux-dash {
- # index index.html index.php;
- #}
- # Pass PHP requests on to PHP-FPM using sockets
- location ~ \.php(/|$) {
- fastcgi_split_path_info ^(.+?\.php)(/.*)$;
- # fastcgi_pass unix:/run/linux-dash.sock;
- # fastcgi_pass linux-dash-sock:9001;
- fastcgi_pass 127.0.0.1:9000;
- # fastcgi_pass unix:/var/run/php5-fpm.sock
- # fastcgi_pass localhost:9000; # using TCP/IP stack
- #if (!-f $document_root$fastcgi_script_name) {
- # return 404;
- #}
- try_files $uri $uri/ /index.php?$args;
- # include fastcgi_params;
- include fastcgi.conf;
- }
- }
- upstream linux-dash-sock{
- # server unix:/var/run/linux-dash.sock;
- server 127.0.0.1:9000;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement