Created
August 30, 2012 14:36
-
-
Save rsky/3529774 to your computer and use it in GitHub Desktop.
rep2用 Nginx設定サンプル
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; | |
server_name rep2.example.com; | |
access_log /path/to/p2-php/data/logs/access.log main; | |
error_log /path/to/p2-php/data/logs/error.log; | |
ssl on; | |
ssl_protocols SSLv3 TLSv1; | |
ssl_ciphers HIGH:!ADH:!MD5; | |
ssl_prefer_server_ciphers on; | |
ssl_certificate com.example.rep2.crt; | |
ssl_certificate_key com.example.rep2.key; | |
ssl_session_timeout 5m; | |
#ssl_verify_client on; | |
#ssl_verify_depth 4; | |
#ssl_client_certificate cacert.pem; | |
#ssl_crl crl.pem; | |
gzip on; | |
gzip_types text/plain | |
text/css | |
text/javascript | |
application/xml | |
application/xhtml+xml | |
application/rss+xml | |
application/atom+xml | |
application/javascript | |
application/x-javascript; | |
gzip_vary on; | |
location / { | |
root /path/to/p2-php/rep2; | |
index index.php index.html; | |
location ~ \.php$ { | |
fastcgi_pass 127.0.0.1:9000; | |
fastcgi_index index.php; | |
include fastcgi_params; | |
fastcgi_param HTTPS on; | |
fastcgi_param SSL_PROTOCOL $ssl_protocol; | |
fastcgi_param SSL_CIPHER $ssl_cipher; | |
fastcgi_param SSL_SESSION_ID $ssl_session_id; | |
fastcgi_param SSL_CLIENT_VERIFY $ssl_client_verify; | |
fastcgi_param SCRIPT_FILENAME /path/to/p2-php/rep2$fastcgi_script_name; | |
break; | |
} | |
location ~ \.(html|css|js|jpg|png|gif)$ { | |
expires 30d; | |
break; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment