#user  nobody;
worker_processes ; #error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info; #pid logs/nginx.pid; events {
worker_connections ;
} 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 ;
keepalive_timeout ; #gzip on; upstream ly.com{
server 192.168.1.211: weight=;
server 192.168.1.211: weight=;
server 192.168.1.211: weight=;
} server {
listen ;
server_name localhost; #charset koi8-r; #access_log logs/host.access.log main; location / {
#root html;
#index index.html index.htm;
proxy_pass http://ly.com;
proxy_redirect default;
} location /status {
stub_status on;
access_log /nginx/logs/status.log;
auth_basic "NginxStatus";
} #error_page /.html; # redirect server error pages to the static page /50x.html
#
error_page /50x.html;
location = /50x.html {
root html;
} # proxy the PHP scripts to Apache listening on 127.0.0.1:
#
#location ~ \.php$ {
# proxy_pass http://127.0.0.1;
#} # pass the PHP scripts to FastCGI server listening on 127.0.0.1:
#
#location ~ \.php$ {
# root html;
# fastcgi_pass 127.0.0.1:;
# 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 ;
# listen somename:;
# server_name somename alias another.alias; # location / {
# root html;
# index index.html index.htm;
# }
#} # HTTPS server
#
#server {
# listen 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;
# }
#} }

Ngin 简单配置文件的更多相关文章

  1. C 构造一个 简单配置文件读取库

    前言 最近看到这篇文章, json引擎性能对比报告 http://www.oschina.net/news/61942/cpp-json-compare?utm_source=tuicool 感觉技术 ...

  2. 用C语言实现解析简单配置文件的小工具

    本文介绍作者写的一个小工具,简单的代码中包含了C语言对字符串的处理技巧,对文本文件的简单解析,二进制文件的数据复制的方法,以及格式化输出文本文件的示例. 工具的输入是如下内容的配置文件: ;资源管理器 ...

  3. centos vim 7.3 升级 + vim 简单配置文件

    CentOS5自带VIM为2006年的7.0版本,现在很多插件都是针对7.3开发的,决定编译升级VIM7.3版. 编译安装VIM7.3: cd /usr/local/src/ wget ftp://f ...

  4. spring基础学习---简单配置文件

  5. 配置文件和sqlplus简单使用

    oracle简单配置文件 数据文件目录 D:\app\inmeditation\oradata\orcl 以.CTL结尾得的文件是数据库的控制文件 以.LOG结尾的是数据库日志文件 以.DBF结尾的是 ...

  6. C 封装一个简单二叉树基库

    引文 今天分享一个喜欢佩服的伟人,应该算人类文明极大突破者.收藏过一张纸币类型如下 那我们继续科普一段关于他的简介 '高斯有些孤傲,但令人惊奇的是,他春风得意地度过了中产阶级的一生,而  没有遭受到冷 ...

  7. XMemcached简单使用示例

    Memcached的Java客户端目前有三个: Memcached Client for Java 比 SpyMemcached更稳定.更早.更广泛: SpyMemcached 比 Memcached ...

  8. ganglia-gmond.conf配置文件

    运行下列命令可以生成gmond默认配置文件: User@host:$ gmond -t 配置文件由大括弧括起来的几个section组成.这些section可以粗略划分为两个逻辑分类.第一类中的sect ...

  9. Angular2配置文件详解

    初学接触Angular2的时候,通过ng new your-project-name 命令生成一个工程空壳,本文来介绍下每个文件的作用及含义. 先来看看src的文件目录: 文件详解 File 文件 P ...

随机推荐

  1. 用word2016 写CSDN 博客

    目前大部分的博客作者在用Word写博客这件事情上都会遇到以下3个痛点: 1.所有博客平台关闭了文档发布接口,用户无法使用Word,Windows Live Writer等工具来发布博客.使用Word写 ...

  2. SQLITE3的锁以及事务

    以下内容摘自<SQLITE权威指南>,下载地址http://download.csdn.net/detail/cxjchen/5643391   SQLITE的锁 在SQLite中,锁和事 ...

  3. sun.misc.BASE64Decoder的风险

    问题描述 最近需要使用Base64上传图片,但是返现sun.misc.BASE64Decoder 为已经过期的包,此包为以前sun公司的内部包,可以下载此包,但是不利于现在Maven方式构建,可能会在 ...

  4. DateUtils常用方法

    一.DateUtils常用方法   1.1.常用的日期判断 isSameDay(final Date date1, final Date date2):判断两个时间是否是同一天: isSameInst ...

  5. tomcat启动时就频繁gc和full gc

    一个小业务,流量并不大,功能也很简单,spring framework+mybatis+quartz,一启动就看到gc的频次和full gc的频次非常高: 4.202: [Full GC 4.202: ...

  6. 看懂gc日志

    使用的是:+PrintGCDetails -XX:+PrintGCTimeStamps 输出的日志格式: [Times: user=0.03 sys=0.00, real=0.01 secs] 363 ...

  7. EF查询记录

    public void TestMethod1() { , Ids = , Ids = "4,5,6" } }; , , , , , , , }; var query = quer ...

  8. .net后台转json数据

    List<PostInfo> list = new List<PostInfo>();PostInfo postinfo = new PostInfo();list.Add(p ...

  9. Sql Server中使用存储过程来实现一些时间差的改变

    Sql Server中的时间差是使用DATEDIFF来是现的 语法如下:DATEDIFF(要显示时间格式,开始时间,结束时间) 比如:DATEDIFF(minute,'2019-2-28 8:30', ...

  10. Thread类

    Thread类相对于线程池中的线程,使用者有更多的控制权.该类允许创建前台线程,设置线程优先级等.Thread类的构造函数重载为接受ThreadStart和ParameterizedThreadSta ...