1
Web Proxy Filtering and Caching / Re: Reverse proxying Omada SDN via HAProxy
« on: August 18, 2022, 08:38:49 pm »
HA Proxy Setup for Omada
### Omada Conditions ###
### Omada Rules ###
### Public Service ###
### Omada Conditions ###
Code: [Select]
oc_condition_1
Condition type = Host matches
Host String = omada.domain.tld (your public domain)
oc_condition_2
Condition type = Host regex
Host Regex = ^omada\.domain\.ltd(:([0-9]){1,5})?$
### Omada Rules ###
Code: [Select]
oc_rule_1
Test type = IF[default]
Select conditions = oc_condition_1
Execute function = Use specified Backend Pool
Use Backend pool = omada_pool
oc_rule_2
Test type = IF[default]
Select conditions = oc_condition_1,oc_condition_2
Execute function = http-request header set
HTTP Header = host
Header Content = omada.domain.tld:8043
oc_rule_3
Select conditions = Nothing selected
Execute function = Custom Rule
Option pass-through = http-response replace-value location 8043 %[hdr(location),regsub(8043,443)]
### Omada Server ###Code: [Select]
omada_server
Type = static
FQDN or IP = 192.168.1.0 (your localhost ip)
Port = 8043
Mode = active
SSL = true
Verify SSL Certificate = false
### Omada Pool ###Code: [Select]
omada_pool
Servers = omada_server
Select Rules = oc_rule_2,oc_rule_3
### Public Service ###
Code: [Select]
public_https
Select Rules = oc_rule_1