Skip to content

Instantly share code, notes, and snippets.

@chrismeller
Created April 14, 2015 23:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chrismeller/dd25fa21566f381d21ad to your computer and use it in GitHub Desktop.
Save chrismeller/dd25fa21566f381d21ad to your computer and use it in GitHub Desktop.
server {
listen [::]:80;
listen *:80;
server_name blog.chrismeller.com;
root /home/chris/public_html/blog.chrismeller.com/public;
access_log /home/chris/public_html/blog.chrismeller.com/logs/access.log;
error_log /home/chris/public_html/blog.chrismeller.com/logs/error.log;
location ~ /\.git {
deny all;
}
location /habari/ {
# force ssl for login and admin pages
rewrite ^/habari/(admin|auth)(.*) https://$host$request_uri?;
try_files $uri $uri/ /habari/index.php$is_args$args;
}
location ~ \.php$ {
fastcgi_pass php;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment