Nginx Learning Notes

Source: Internet
Author: User
Background

Nginx Service Configuration and usage

Process description

Launch the service in a http://openresty.org/cn/getting-started.html way.
The commands used are:
Path=/usr/local/openresty/nginx/sbin: $PATH
Export PATH
Then we start the Nginx server with our config file:
Nginx-p pwd /-C conf/nginx.conf
The-p is mainly to indicate the configuration directory of Nginx startup, and-c specifies a configuration file for Nginx instead of the default.
If you modify the nginx.conf file, use the following statement to perform the service's reload operation.

/usr/local-s-p`pwd`/-c conf/nginx.conf

Note the path where the command line originated.

To test the initial code:

worker_processes  1;error_log logs/error.log;events {    1024;}http {    server {        8080;        location / {            text/html;            content_by_lua_file /home/liujiepeng/work/test.lua;            content_by_lua '                local"zlib"local v,mv,pv=zlib.version()                ngx.say"  ""  " .. pv)                ngx.say("

hello12343, world

") '; } }}

Additional Information

One of the zlib installation and compilation can ask Google, basically is make,make install. The install operation is to copy so files to the corresponding folder under Nginx.

'). addclass (' pre-numbering '). Hide (); $ (this). addclass (' has-numbering '). Parent (). append ($numbering); for (i = 1; i <= lines; i++) {$numbering. Append ($ ('
  • '). Text (i)); }; $numbering. FadeIn (1700); }); });

    The above describes the Nginx learning notes, including aspects of the content, I hope that the PHP tutorial interested in a friend helpful.

  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.