https和http共存的nginx配置
server {
listen 80;
listen 443 ssl;
server_name test.xx.com;
index index.html index.htm index.php;
root /usr/local/default;
location ~ .*\.(php|php5)?$
{
#fastcgi_pass unix:/tmp/php-cgi.sock;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi.conf;
}
location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
#expires 30d;
}
location ~ .*\.(js|css)?$
{
#expires 1h;
}
access_log logs/test.access.log;
ssl_certificate /x.com_bundle.crt;
ssl_certificate_key /x.com.key;
ssl_session_timeout 5m;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers AESGCM:ALL:!DH:!EXPORT:!RC4:+HIGH:!MEDIUM:!LOW:!aNULL:!eNULL;
ssl_prefer_server_ciphers on;
}
https和http共存的nginx配置的更多相关文章
- nginx的https和http共存反向代理配置
一.设置http反向代理: upstream ly.com { server ; server ; } upstream home.ly.com { server ; server ; } 对应增加: ...
- https和http共存的nginx简单配置
server{ listen 80; listen 443 ssl; ssl_certificate /usr/local/nginx/ssl/www.demo.com/www.demo.com.cn ...
- [转] Nginx 配置 SSL 证书 + 搭建 HTTPS 网站教程
一.HTTPS 是什么? 根据维基百科的解释: 超文本传输安全协议(缩写:HTTPS,英语:Hypertext Transfer Protocol Secure)是超文本传输协议和SSL/TLS的组合 ...
- Nginx 配置 SSL 证书 + 搭建 HTTPS 网站教程
一.HTTPS 是什么? 根据维基百科的解释: 超文本传输安全协议(缩写:HTTPS,英语:Hypertext Transfer Protocol Secure)是超文本传输协议和SSL/TLS的组合 ...
- nginx 配置支持URL HTML5 History 模式 与 设置代理
拾人牙慧:https://segmentfault.com/q/1010000007140360 nginx 配置支持URL HTML5 History 模式 location / { try_fil ...
- nginx 配置https没有ssl_module以及一些错误
一:开始Nginx的SSL模块 1.1 Nginx如果未开启SSL模块,配置Https时提示错误 1 nginx: [emerg] the "ssl" parameter requ ...
- nginx 配置https并自签名证书
2016-10-28 转载请注明出处:http://daodaoliang.com/ 作者: daodaoliang 版本: V1.0.1 邮箱: daodaoliang@yeah.net 参考链接: ...
- Nginx配置Https指南
前言 本文是对Nginx配置SSL证书的总结. 申请SSL证书 你可以从任何证书提供商处申请证书,这里以阿里云为例. 打开阿里云SSL证书控制台,点击购买证书 选择免费型一年期的证书,点击立即购买 注 ...
- Windows下Nginx配置SSL实现Https访问(包含证书生成)
Vincent.李 Windows下Nginx配置SSL实现Https访问(包含证书生成) Windows下Nginx配置SSL实现Https访问(包含证书生成) 首先要说明为什么要实现https ...
随机推荐
- HDU 5253 最小生成树(kruskal)+ 并查集
题目链接 #include<cstdio> #include<cmath> #include<cstring> #include<algorithm> ...
- GridView 分页方法
要实现GrdView分页的功能. 操作如下: 1.更改GrdView控件的AllowPaging属性为true. 2.更改GrdView控件的PageSize属性为 任意数值(默认为10) 3.更改G ...
- LCA(倍增)
type arr=record v,nt:longint; end; ; lx=; ..maxn] of longint; eg:..maxn*] of arr; d:..maxn] of longi ...
- Why does my ListView scroll to the top when navigating backwards?
I’ve seen a few people asking this question. They have a page which contains a ListView and when an ...
- C++学习笔记15:操作符重载的函数原型列表(推荐)
//普通四则运算 friend A operator +(const A & lhs, const A & rhs); friend A operator -(const A & ...
- LeetCode Longest Increasing Subsequence (LIS O(nlogn))
题意: 给一个数组,求严格递增的最长递增子序列的长度. 思路: 开销是一个额外的O(n)的数组.lower_bound(begin,end,val)的功能是:返回第一个大于等于val的地址. clas ...
- BLP模型
编号:1002时间:2016年3月29日16:24:33功能:多级安全BLP模型 URL:http://blog.csdn.net/longronglin/article/details/150033 ...
- 【Repost】A Practical Intro to Data Science
Are you a interested in taking a course with us? Learn about our programs or contact us at hello@zip ...
- PAT (Basic Level) Practise:1027. 打印沙漏
[题目链接] 本题要求你写个程序把给定的符号打印成沙漏的形状.例如给定17个“*”,要求按下列格式打印 ***** *** * *** ***** 所谓“沙漏形状”,是指每行输出奇数个符号:各行符号中 ...
- node实现http上传文件进度条 -我们到底能走多远系列(37)
我们到底能走多远系列(37) 扯淡: 又到了一年一度的跳槽季,相信你一定准备好了,每每跳槽,总有好多的路让你选,我们的未来也正是这一个个选择机会组合起来的结果,所以尽可能的找出自己想要的是什么再做决定 ...