summaryrefslogtreecommitdiff
path: root/caddytest
diff options
context:
space:
mode:
authorFrancis Lavoie <lavofr@gmail.com>2022-03-01 16:12:43 -0500
committerGitHub <noreply@github.com>2022-03-01 14:12:43 -0700
commit87a1f228b4c48db7bdab694cf0fd1c76243f29f3 (patch)
tree215e92369cf9bbba043bee5b15d198be7b876f64 /caddytest
parentacbee9470818a32f77634b0c0943bc0544f6e736 (diff)
reverseproxy: Move status replacement intercept to `replace_status` (#4300)
Diffstat (limited to 'caddytest')
-rw-r--r--caddytest/integration/caddyfile_adapt/reverse_proxy_handle_response.txt22
1 files changed, 11 insertions, 11 deletions
diff --git a/caddytest/integration/caddyfile_adapt/reverse_proxy_handle_response.txt b/caddytest/integration/caddyfile_adapt/reverse_proxy_handle_response.txt
index 35d9631..88ecbc2 100644
--- a/caddytest/integration/caddyfile_adapt/reverse_proxy_handle_response.txt
+++ b/caddytest/integration/caddyfile_adapt/reverse_proxy_handle_response.txt
@@ -1,6 +1,9 @@
:8884
reverse_proxy 127.0.0.1:65535 {
+ @changeStatus status 500
+ replace_status @changeStatus 400
+
@accel header X-Accel-Redirect *
handle_response @accel {
respond "Header X-Accel-Redirect!"
@@ -38,9 +41,6 @@ reverse_proxy 127.0.0.1:65535 {
handle_response @multi {
respond "Headers Foo, Bar AND statuses 401, 403 and 404!"
}
-
- @changeStatus status 500
- handle_response @changeStatus 400
}
----------
{
@@ -58,6 +58,14 @@ reverse_proxy 127.0.0.1:65535 {
"handle_response": [
{
"match": {
+ "status_code": [
+ 500
+ ]
+ },
+ "status_code": 400
+ },
+ {
+ "match": {
"headers": {
"X-Accel-Redirect": [
"*"
@@ -156,14 +164,6 @@ reverse_proxy 127.0.0.1:65535 {
]
},
{
- "match": {
- "status_code": [
- 500
- ]
- },
- "status_code": 400
- },
- {
"routes": [
{
"handle": [