vhost: Add option to find and replace headers in reverse proxy

This commit is contained in:
uumas
2026-03-11 22:13:29 +02:00
parent 080c5b4dc2
commit 3013d3edf0
4 changed files with 83 additions and 0 deletions

View File

@@ -46,6 +46,25 @@ argument_specs:
type: dict
required: false
default: {}
vhost_find_replace_headers:
description: Response headers to find and replace
type: list
elements: dict
required: false
default: []
options:
header:
description: Header to modify
type: str
required: true
find:
description: Header content to find
type: str
required: true
replace:
description: Content to replace matching headers with
type: str
required: true
vhost_delete_headers:
description: List of reponse headers to delete
type: list
@@ -242,6 +261,25 @@ argument_specs:
type: dict
required: false
default: "{{ vhost_headers }}"
find_replace_headers:
description: Response headers to find and replace
type: list
elements: dict
required: false
default: "{{ vhost_find_replace_headers }}"
options:
header:
description: Header to modify
type: str
required: true
find:
description: Header content to find
type: str
required: true
replace:
description: Content to replace matching headers with
type: str
required: true
delete_headers:
description: List of response headers to delete
type: list
@@ -414,6 +452,25 @@ argument_specs:
type: dict
required: false
default: "{{ vhost_headers }}"
find_replace_headers:
description: Response headers to find and replace
type: list
elements: dict
required: false
default: "{{ vhost_find_replace_headers }}"
options:
header:
description: Header to modify
type: str
required: true
find:
description: Header content to find
type: str
required: true
replace:
description: Content to replace matching headers with
type: str
required: true
delete_headers:
description: List of response headers to delete
type: list
@@ -610,6 +667,24 @@ argument_specs:
description: Dict of response headers and their values
type: dict
required: false
find_replace_headers:
description: Response headers to find and replace
type: list
elements: dict
required: false
options:
header:
description: Header to modify
type: str
required: true
find:
description: Header content to find
type: str
required: true
replace:
description: Content to replace matching headers with
type: str
required: true
delete_headers:
description: List of response headers to delete
type: list