Nginx Module Reference Manual: Uwsgi module (UWSGI)

Source: Internet
Author: User
Keywords NGINX UWSGI UWSGI Module
Tags aliyun compiled configuration configure default default value example html

These modules are all compiled into Nginx by default unless a module is manually specified to be excluded in configure.

Provide support for the UWSGI protocol.
Sample configuration:

Location/{Uwsgi_pass unix:///var/run/example.com.sock; include uwsgi_http://www.aliyun.com/zixun/aggregation/12616.html ">params; }

Be careful not to confuse the UWSGI protocol with the UWSGI server.

Instructions

Uwsgi_pass

Syntax: Uwsgi_pass URI
Default value: None
Working with fields: server, location
Set up a listener address for a UWSGI compatible server (TCP sockets, UNIX sockets, or flow blocks)

Uwsgi_param

Syntax: Uwsgi_param key value
Default value: None
Working with fields: server, location
Adds a pair of key/value values for a UWSGI request.
Example:

Location/{Uwsgi_pass unix:///var/run/example.com.sock; include uwsgi_params; Uwsgi_param new_var foo;}

Uwsgi_modifier1

Syntax: Uwsgi_modifier1 value
Default value: 0
Working with fields: server, location
Sets the first modifier for a UWSGI request (the default is a WSGI request).

Uwsgi_modifier2

Syntax: Uwsgi_modifier2 value
Default value: 0
Working with fields: server, location
Sets a second modifier for a UWSGI request.

Uwsgi_string

Syntax: uwsgi_string string
Default value: None
Working with fields: server, location
Adds a string for a UWSGI request.
Example (for a UWSGI compatible server that supports the eval modifier):

Location/{Uwsgi_pass unix:///var/run/example.com.sock; uwsgi_pass_request_headers off; Uwsgi_pass_request_body off; Uwsgi_string "Import Uwsgi uwsgi.start_response (' OK ', [(' Content-type ', ' filetype ')]" total = 30+22uwsgi.send ("30 + =%d "% total"; Uwsgi_modifier1 22; Uwsgi_modifier2 0; }

Uwsgi_pass_request_headers

Syntax: Uwsgi_pass_request_headers on/off
Default value: On
Working with fields: server, location
The HTTP request header is passed in the UWSGI request.

Uwsgi_pass_request_body

Syntax: Uwsgi_pass_request_body on/off
Default value: On
Working with fields: server, location
Pass the HTTP request entity (if it is available) in the UWSGI request.

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.