我配了个证书,要求要时https 访问,我只要求ip能够访问就可以,必须是443端口,但是我配置好后,配置好后对应的index.html路径能够访问,但是php 页面却不能访问,不知道是什么原因。
这个是nginx 配置:
server {
listen 443 ssl;
server_name xxx.cn;
root /www/wwwroot/paopao/cgi;
index index.html index.htm;
ssl_certificate ssl/xx.crt;
ssl_certificate_key ssl/xx.key;
#ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;
#ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
#ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
#ssl_prefer_server_ciphers on;
location / {
index index.php index.html index.htm;
#autoindex on;
}
location ~ \.php(.*)$ {
root /www/wwwroot/paopao/cgi;
fastcgi_pass 127.0.0.1:9000;
#fastcgi_pass unix:/dev/shm/php-cgi.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi.conf;
}
}
|
|