Nginx配置简介(一)

配置简介

nginx.conf配置文件,基本就分为以下几块:

main

events   {

  ....}

http        {

  ....

  upstream myproject {

    .....

  }

  server  {

    ....

    location {

        ....

    }

  }

  server  {

    ....

    location {

        ....

    }

  }

  ....}


nginx配置文件主要分为六个区域:

· main(全局设置)

· events(nginx工作模式)

· http(http设置)

· sever(主机设置)

· location(URL匹配)

· upstream(负载均衡服务器设置)

猜你喜欢

转载自blog.csdn.net/qq_35448976/article/details/79512722