Edge Rules
Edge rules support conditional evaluation with any, all, or none matching and two condition fields:
request_url: Regular expression matching for the request path.remote_ip: Regular expression matching against client source IP.
Available actions:
set_request_header: Injects a header before origin proxying.override_origin_url: Rewrites upstream origin URL dynamically.
Path placeholders can be used in action values: %{Path.0}, %{Path.1}, %{Path.0-}.
Rule Evaluation Details
How matching works
- Rule-level match controls whether any, all, or none of conditions must match.
- Condition-level match falls back to rule-level match if not explicitly set.
- If multiple rules are enabled, they are evaluated in configured order.
- Actions run for each matched rule, so order matters when two rules touch the same header.
Pattern and placeholder notes
- Use regex patterns for request_url like ^/media/.*$ or /iptv-[0-9]+/master\.m3u8$/.
- remote_ip supports regex patterns for source IP matching.
- override_origin_url supports path placeholders, for example %{Path.0}.
- set_request_header is best for upstream auth headers or routing metadata.