Certbot-nginx: Expected string_end, found 'http'

Hi @hf147,

Thanks for sharing your configuration. I was able to reproduce the parsing problem and narrow it down to lines 46-48

which are commented-out portions of your multiline log_format definition. These cause Certbot's nginx parser to get confused and fail. (I'm guessing that perhaps some portion of the parser's handling of quotation marks doesn't realize that quotation marks should be ignored when they occur inside a line that's commented out?)

Certbot should work if you delete these three commented-out lines from your configuration, but we could also let the @certbot-devs know that there is yet another unusual case that may be worth handling in the nginx parser.

5 Likes