A page about the grammar of Nginx
nginx consists of modules which are controlled by directives specified in the configuration file.
Directives are divided into simple directives and block directives.
A block directive consists of the name and parameters and a set of additional instructions surrounded by braces ({ and }).
Directives placed in the configuration file outside of any contexts are considered to be in the main context. The events and http directives reside in the main context, server in http, and location in server.
Condition are in the rewrite module. For example, the If directive
The rest of a line after the # sign is considered a comment.