Quick Start
This guide walks you through a minimal working configuration that routes traffic from a domain list through a VPN interface.
Minimal Configuration
Create /etc/keen-pbr/config.json:
{
"daemon": {
"pid_file": "/var/run/keen-pbr.pid",
"cache_dir": "/var/cache/keen-pbr"
},
"outbounds": [
{
"type": "interface",
"tag": "vpn",
"interface": "tun0",
"gateway": "10.8.0.1"
},
{
"type": "interface",
"tag": "wan",
"interface": "eth0",
"gateway": "192.168.1.1"
}
],
"lists": {
"my-domains": {
"domains": ["example.com", "*.example.org"]
}
},
"route": {
"rules": [
{
"list": ["my-domains"],
"outbound": "vpn"
}
],
"fallback": "wan"
}
}This config:
- Defines two outbounds:
vpn(tun0) andwan(eth0) - Creates a list
my-domainswith two inline domain entries - Routes all traffic matching
my-domainsthroughvpn - Falls back to
wanfor everything else
Run the Daemon
keen-pbr --config /etc/keen-pbr/config.jsonAdd -d to run as a background daemon:
keen-pbr --config /etc/keen-pbr/config.json -dVerify Routing
Enable the API in your config ("api": {"enabled": true}), then check the routing health:
curl http://127.0.0.1:8080/api/health/routingA healthy response looks like:
{
"overall": "ok",
"firewall_backend": "nftables",
"firewall": {
"chain_present": true,
"prerouting_hook_present": true
},
"firewall_rules": [...],
"route_tables": [...],
"policy_rules": [...]
}If overall is degraded, check the individual entries for missing or mismatch statuses.
For a complete configuration reference including remote lists, DNS routing, urltest failover, and advanced filtering, see the Configuration section.