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
### Password Protect /administrator area | |
location ~ /administrator/.* { | |
auth_basic "Restricted"; | |
auth_basic_user_file /var/www/prod.pac.cr/passwd; | |
fastcgi_split_path_info ^(.+\.php)(/.+)$; | |
# NOTE: You should have "cgi.fix_pathinfo = 0;" in php.ini | |
# With php5-cgi alone: | |
#fastcgi_pass 127.0.0.1:9000; | |
# With php5-fpm: |
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 443 spdy; | |
listen 80; | |
server_name foo.org www.foo.org; | |
root /home/site/public; | |
#if ($request_method !~ "^(GET|HEAD|POST)$" ) { return 444; } | |
if ($https != 'on') { return 301 https://www.foo.org$request_uri; } | |
if ($host = "foo.org") { return 301 https://www.foo.org$request_uri; } |