- 浏览: 86216 次
文章分类
最新评论
<参看》http://www.cnblogs.com/sunxucool/p/3225818.html
# 定义Nginx运行的用户和用户组(?)
#user nobody;
#开启进程数(通常等于CPU数量或者2倍于CPU)
worker_processes 1;
##错误日志保存位置 定义类型,[ debug | info | notice | warn | error | crit ]
#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;
#进程号日志
#pid logs/nginx.pid;
#等待事件
events {
(#Linux 2.6以上版本内核中的高性能网络I/O模型
#use epoll;
)
#单个进程最大连接数(最大连接=连接数x进程数)
worker_connections 1024;
}
#设定http服务器
http {
#文件扩展名与文件类型映射表
include mime.types;
#默认文件类型
default_type application/octet-stream;
#日志文件输出格式 相当于全局设置
#log_format main '$remote_addr - $remote_user [$time_local] "$request" '
# '$status $body_bytes_sent "$http_referer" '
# '"$http_user_agent" "$http_x_forwarded_for"';
#请求日志保存位置
#access_log logs/access.log main;
#开启高效文件传输模式
sendfile on;
#防止网络阻塞
#tcp_nopush on;
##长连接超时时间,单位是秒
#keepalive_timeout 0;
keepalive_timeout 65;
#打开gzip压缩
#gzip on;
#第一个虚拟主机
server {
#监听端口
listen 8181;
#主机名 域名可以有多个,用空格隔开
server_name localhost; (192.168.0.101 192.168.0.102)
#设置字符集
#charset koi8-r;
#本虚拟server的访问日志 相当于局部变量
#access_log logs/host.access.log main;
#静态文件
location / {
root html;
index index.html index.htm;
}
#error_page 404 /404.html;
# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
# proxy the PHP scripts to Apache listening on 127.0.0.1:80
#
#location ~ \.php$ {
# proxy_pass http://127.0.0.1;
#}
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
#location ~ \.php$ {
# root html;
# fastcgi_pass 127.0.0.1:9000;
# fastcgi_index index.php;
# fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
# include fastcgi_params;
#}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}
# another virtual host using mix of IP-, name-, and port-based configuration
#
#server {
# listen 192.168.0.103:8080;
# server_name ;other server name
# location / {
#WEB文件路径
# root html;
# index index.html index.htm;
# }
#}
# HTTPS server
#ssl加密服务器
#server {
# listen 443 ssl;
# server_name localhost;
# ssl_certificate cert.pem;
# ssl_certificate_key cert.key;
# ssl_session_cache shared:SSL:1m;
# ssl_session_timeout 5m;
# ssl_ciphers HIGH:!aNULL:!MD5;
# ssl_prefer_server_ciphers on;
# location / {
# root html;
# index index.html index.htm;
# }
#}
}
# 定义Nginx运行的用户和用户组(?)
#user nobody;
#开启进程数(通常等于CPU数量或者2倍于CPU)
worker_processes 1;
##错误日志保存位置 定义类型,[ debug | info | notice | warn | error | crit ]
#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;
#进程号日志
#pid logs/nginx.pid;
#等待事件
events {
(#Linux 2.6以上版本内核中的高性能网络I/O模型
#use epoll;
)
#单个进程最大连接数(最大连接=连接数x进程数)
worker_connections 1024;
}
#设定http服务器
http {
#文件扩展名与文件类型映射表
include mime.types;
#默认文件类型
default_type application/octet-stream;
#日志文件输出格式 相当于全局设置
#log_format main '$remote_addr - $remote_user [$time_local] "$request" '
# '$status $body_bytes_sent "$http_referer" '
# '"$http_user_agent" "$http_x_forwarded_for"';
#请求日志保存位置
#access_log logs/access.log main;
#开启高效文件传输模式
sendfile on;
#防止网络阻塞
#tcp_nopush on;
##长连接超时时间,单位是秒
#keepalive_timeout 0;
keepalive_timeout 65;
#打开gzip压缩
#gzip on;
#第一个虚拟主机
server {
#监听端口
listen 8181;
#主机名 域名可以有多个,用空格隔开
server_name localhost; (192.168.0.101 192.168.0.102)
#设置字符集
#charset koi8-r;
#本虚拟server的访问日志 相当于局部变量
#access_log logs/host.access.log main;
#静态文件
location / {
root html;
index index.html index.htm;
}
#error_page 404 /404.html;
# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
# proxy the PHP scripts to Apache listening on 127.0.0.1:80
#
#location ~ \.php$ {
# proxy_pass http://127.0.0.1;
#}
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
#location ~ \.php$ {
# root html;
# fastcgi_pass 127.0.0.1:9000;
# fastcgi_index index.php;
# fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
# include fastcgi_params;
#}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}
# another virtual host using mix of IP-, name-, and port-based configuration
#
#server {
# listen 192.168.0.103:8080;
# server_name ;other server name
# location / {
#WEB文件路径
# root html;
# index index.html index.htm;
# }
#}
# HTTPS server
#ssl加密服务器
#server {
# listen 443 ssl;
# server_name localhost;
# ssl_certificate cert.pem;
# ssl_certificate_key cert.key;
# ssl_session_cache shared:SSL:1m;
# ssl_session_timeout 5m;
# ssl_ciphers HIGH:!aNULL:!MD5;
# ssl_prefer_server_ciphers on;
# location / {
# root html;
# index index.html index.htm;
# }
#}
}
发表评论
-
41、解决HttpServletResponse输出的中文乱码问题
2015-04-12 21:48 1171response返回有两种,一种是字节流outputs ... -
41、轮询
2015-04-12 08:50 0浏览器关闭使session失效 ... -
40、spring ajax/easyui 中文乱码的解决
2015-04-04 14:52 655使用spingmvc,在JS里面通过ajax发送请求,并 ... -
39、.net
2015-03-28 23:12 516熟悉java编程,自然学习c#就会比较容易,有几个点需要说明下 ... -
38、servlet-- JSTL+EL(c标签、${})
2015-03-23 15:57 752参看:http://www.cnblogs.com/xdp-g ... -
37、servlet--jsp
2015-03-23 15:07 463不管是JSP还是Servlet,虽然都可以用于开发动 ... -
36、servlet--防止表单重复提交
2015-03-23 14:33 6771、在网络延迟会或服务器反应过慢的情况下让用户有时间点击多次s ... -
35、servlet--servletContext
2015-03-22 13:41 446servletContext接口是Servlet中最大的一个接 ... -
34、servlet--会话技术/购物车demo/y验证码
2015-03-21 23:40 558会话Session and Cookie 1、session: ... -
33、servlet--转发/web开发指导思想
2015-03-21 12:31 415转发: req.getRequestDispatcher(&q ... -
32、servlet --重定向/下载/缓存/中文乱码
2015-03-20 23:21 999重定向1、sendRedirect rep.sendRedir ... -
31、servlet--开发方式
2015-03-20 21:55 600servlet:利用java技术开发动态网页的技术,是学习ja ... -
30、servlet---tomcat原理
2015-03-20 18:20 652Servlet出现得早,servlet很强大,但是se ... -
29、servlet--jsp执行过程
2015-03-20 15:08 412J2EE的13种核心技术:JDBC、JNDI、EJBs、 ... -
29、springmvc+spring+mybatis+oracle12的demo
2015-03-15 20:29 0每次搭建都要重头搭建,累~~ 注意:用12c的jdbc 在安 ... -
27、Tomcat多次加载项目问题
2015-03-12 15:30 513错误配置方式: <Host name="lo ... -
26、数据分页(jsp+servlet)
2015-03-12 15:19 448随着数据库中存储的数据的增多,满足用户查询条件的数据也 ... -
llll.文档设计
2015-03-11 13:31 0设计文档与代码实现到 ... -
24、webservice_短信接口
2015-03-11 10:48 763http://blog.csdn.net/sxdtzhaoxi ... -
25、RMI_demo1
2015-03-11 10:48 406Java RMI 指的是远程方法调用 (Remote Meth ...
相关推荐
nginx_1.7.11.3_Gryphon主要用于媒体直播服务器用,和FFmpeg+nginx+实例视频
slb_nginx.conf
6_nginx.conf
1_nginx.conf
anquan_huayun_nginx.conf
yewu_YG_nginx.conf
nginx.conf配置文件,反向代理,负载均衡--轮询、权重、IPHASH等
Notepad++ 自定义 nginx.conf 文件语法高亮的配置文件 使用教程:点击语言-自定义语言格式-导入(下载的xml文件)-重启notepad++,即可使用
nginx1.21.5 nginx.conf配置文件
nginx.conf配置文件下载
配置了https的nginx.conf文件:修改了端口81,server_name abc.51js.net.cn; #访问的地址; ssl_certificate 1_abc.51js.net.cn_bundle.crt; #上传的CA证书; ssl_certificate_key 2_abc.51js.net.cn.key; #密钥
非常详细的 nginx.conf 配置文件详解,几乎涵盖了该配置文件能用到的所有知识点,喜欢的同学可以下载!希望对你有帮助!
zbx_nginx
Nginx配置文件(nginx.conf)配置详解[定义].pdf
Linux下的Nginx配置文件 修改IP端口即可使用
11919220_ai.eorangeenergy.com_nginx.zip
cd nginx_1.7.11.3_Gryphon,nginx.exe -c conf\nginx-win-rtmp.conf //使用该配置文件!!!!!搞了好久,踩了很多坑,希望能为后来者搭桥铺路。启动rtmp服务器命令对应我的博客Windows下搭建基于nginx的rtmp直播...
django项目上线时完整的nginx.conf文件,直接覆盖上去,修改域名和项目路径就OK了,直接拿走就好,详细部署上线流程我的博客里油介绍
本资源是专门针对本博文的, nginx的反向代理的简单配置文件,给大家使用时做参考,拿走不谢,怎么一定要50字呢?
Windows下的nginx基础配置文件 Windows下的nginx基础配置文件 修改端口IP即可使用