mirror of
https://github.com/caddyserver/caddy.git
synced 2024-12-23 22:27:38 -05:00
1 KiB
1 KiB
:80 { @matcher { method GET } respond @matcher "get"
@matcher2 method POST
respond @matcher2 "post"
@matcher3 not method PUT
respond @matcher3 "not put"
}
{ "apps": { "http": { "servers": { "srv0": { "listen": [ ":80" ], "routes": [ { "match": [ { "method": [ "GET" ] } ], "handle": [ { "body": "get", "handler": "static_response" } ] }, { "match": [ { "method": [ "POST" ] } ], "handle": [ { "body": "post", "handler": "static_response" } ] }, { "match": [ { "not": [ { "method": [ "PUT" ] } ] } ], "handle": [ { "body": "not put", "handler": "static_response" } ] } ] } } } } }