Created
August 12, 2014 13:01
-
-
Save nramsbottom/f5c376bb7a6d70bf0f85 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # basic example configuration for nginx with php-fpm | |
| server { | |
| root /usr/share/nginx/www; | |
| index index.html index.htm; | |
| server_name localhost; | |
| location /app1 { | |
| alias /usr/share/nginx/apps/app1; | |
| } | |
| location /app2 { | |
| alias /usr/share/nginx/apps/app2; | |
| } | |
| location /app3 { | |
| index index.php; | |
| alias /usr/share/nginx/apps/app3; | |
| location ~ \.php$ { | |
| fastcgi_split_path_info ^(.+\.php)(/.+)$; | |
| fastcgi_pass unix:/var/run/php5-fpm.sock; | |
| fastcgi_index index.php; | |
| include fastcgi_params; | |
| } | |
| } | |
| location / { | |
| try_files $uri $uri/ /index.html; | |
| } | |
| location ~ \.php$ { | |
| fastcgi_split_path_info ^(.+\.php)(/.+)$; | |
| fastcgi_pass unix:/var/run/php5-fpm.sock; | |
| fastcgi_index index.php; | |
| include fastcgi_params; | |
| } | |
| } # end-server |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment