HTTP Plus key-value directives

keyval

HTTP context; commercial. Looks up a key in the named shared zone and assigns the value to a variable. Missing-key policy must be explicit.

Formal Syntax & Structure

nginx syntaxnginx
keyval key $variable zone=name;

Parameters & Attributes

NameTypeDescription
keyexpressionLookup key.
variable$variableDestination variable.
zonezone=namePreviously defined key-value zone.

Working Example

Example Snippetnginx
keyval $arg_region $region_label zone=labels;
Nginx Reference