File: multiline_quotes.conf

package info (click to toggle)
python-certbot-nginx 4.0.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 660 kB
  • sloc: python: 4,507; sh: 47; makefile: 11
file content (16 lines) | stat: -rw-r--r-- 585 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
# Test nginx configuration file with multiline quoted strings.
# Good example of usage for multilined quoted values is when
# using Openresty's Lua directives and you wish to keep the
# inline Lua code readable.
http {
  server {
      listen *:443; # because there should be no other port open.

      location / {
        body_filter_by_lua 'ngx.ctx.buffered = (ngx.ctx.buffered or "") .. string.sub(ngx.arg[1], 1, 1000)
                            if ngx.arg[2] then
                              ngx.var.resp_body = ngx.ctx.buffered
                            end';
      }
  }
}