diff options
author | Matthew Holt <mholt@users.noreply.github.com> | 2020-11-24 16:36:58 -0700 |
---|---|---|
committer | Matthew Holt <mholt@users.noreply.github.com> | 2020-11-24 16:36:58 -0700 |
commit | 63afffc2e317579a5bc618d5441ac238127114a0 (patch) | |
tree | 984ba3d0a53be656913dfb7fe599aba8e1adf694 /caddytest/integration | |
parent | 2d5498ee6f298703b5934a8f8889fa02778d08aa (diff) |
httpcaddyfile: Proper log config with catch-all blocks (fix #3878)
Diffstat (limited to 'caddytest/integration')
-rw-r--r-- | caddytest/integration/caddyfile_adapt/log_except_catchall_blocks.txt | 80 |
1 files changed, 80 insertions, 0 deletions
diff --git a/caddytest/integration/caddyfile_adapt/log_except_catchall_blocks.txt b/caddytest/integration/caddyfile_adapt/log_except_catchall_blocks.txt new file mode 100644 index 0000000..a6fd051 --- /dev/null +++ b/caddytest/integration/caddyfile_adapt/log_except_catchall_blocks.txt @@ -0,0 +1,80 @@ +http://localhost:2020 { + log + file_server +} + +:2020 { + respond 418 +} +---------- +{ + "apps": { + "http": { + "servers": { + "srv0": { + "listen": [ + ":2020" + ], + "routes": [ + { + "match": [ + { + "host": [ + "localhost" + ] + } + ], + "handle": [ + { + "handler": "subroute", + "routes": [ + { + "handle": [ + { + "handler": "file_server", + "hide": [ + "./Caddyfile" + ] + } + ] + } + ] + } + ], + "terminal": true + }, + { + "handle": [ + { + "handler": "subroute", + "routes": [ + { + "handle": [ + { + "handler": "static_response", + "status_code": 418 + } + ] + } + ] + } + ], + "terminal": true + } + ], + "automatic_https": { + "skip": [ + "localhost" + ] + }, + "logs": { + "logger_names": { + "localhost:2020": "" + }, + "skip_unmapped_hosts": true + } + } + } + } + } +}
\ No newline at end of file |