zoukankan      html  css  js  c++  java
  • nginx 下配置https 访问提示下载文件 解决方法

    nginx 下配置https  访问php文件提示下载文件   解决方法

    本地证书放入cert文件后   修改nginx 的配置文件   (这是正确的配置文件php为编译安装)

    server {
    listen 443 ssl;
    server_name www.lvyanshi.com;       ##域名
    root /home/wwwroot/default;            ##网站根目录位置
    index index.html index.htm index.php;   ##主页类型
    ssl_certificate cert/www.lvyanshi.com.pem;      ##证书 
    ssl_certificate_key cert/www.lvyanshi.com.key;   ##秘钥
    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 / {
    root /home/wwwroot/default;        ##网站根目录位置    
    index index.html index.htm index.php;         ##主页类型
    }
    location ~ .*.php$ {
    root /home/wwwroot/default;                             ##网站根目录位置 
    fastcgi_pass unix:/tmp/php-cgi.sock;                ##出现502 报错主要确定这个文件的存储位置在哪
    # fastcgi_pass 127.0.0.1:9000;                         ##开启这个会出现502报错
    try_files $uri /index.php =404;
    fastcgi_split_path_info ^(.+.php)(/.+)$;
    fastcgi_index index.php;
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    include fastcgi_params;

    }

    }

  • 相关阅读:
    SharePoint远程发布Solution
    SharePoint Web Part Error – The Specified Solution Was Not Found
    Visual Studio 2013启用AnkSVN
    Using LINQ to SharePoint
    SharePoint配置搜索服务和指定搜索范围
    SharePoint 站点集和子站点数据互相读取
    SharePoint Backup
    Bootstrap滚动监听
    探索 SharePoint 2013 Search功能
    C#利用iComparable接口实现List排序
  • 原文地址:https://www.cnblogs.com/recall-lonely/p/12572747.html
Copyright © 2011-2022 走看看