Last active
August 29, 2015 14:07
-
-
Save jesseschutt/5f192fefaf87027df5c4 to your computer and use it in GitHub Desktop.
Statamic on Homestead
This file contains 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
server { | |
listen 80; | |
server_name www.example.com; | |
root /home/forge/example.com/public; | |
# FORGE SSL (DO NOT REMOVE!) | |
# ssl on; | |
# ssl_certificate; | |
# ssl_certificate_key; | |
index index.html index.htm index.php; | |
charset utf-8; | |
location ~* ^/_config { | |
deny all; | |
return 404; | |
} | |
location ~ /(_app|_config|_content|/layouts/) { | |
deny all; | |
return 404; | |
} | |
location ~ /.(yml|yaml|html) { | |
deny all; | |
} | |
location / { | |
rewrite ^/admin.php.*$ /admin.php; | |
try_files $uri $uri/ /index.php?$query_string; | |
} | |
location = /favicon.ico { access_log off; log_not_found off; } | |
location = /robots.txt { access_log off; log_not_found off; } | |
access_log off; | |
error_log /var/log/nginx/example.com-error.log error; | |
error_page 404 /index.php; | |
location ~ \.php$ { | |
fastcgi_split_path_info ^(.+\.php)(/.+)$; | |
fastcgi_pass unix:/var/run/php5-fpm.sock; | |
fastcgi_index index.php; | |
include fastcgi_params; | |
} | |
location ~ /\.ht { | |
deny all; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment