{% if ALLOWED_METHODS != "" +%} if ($request_method !~ ^({{ ALLOWED_METHODS }})$) { return 405; } {% endif %}