summaryrefslogtreecommitdiff
path: root/src/migration-scripts/https
diff options
context:
space:
mode:
authorAdam Smith <adamsmith@yzguy.io>2026-10-08 01:20:09 +0000
committerChristian Breunig <christian@breunig.cc>2026-11-07 22:19:52 +0100
commit9babe4468dec43d2df20488bacd3877d77c42b35 (patch)
tree5e2b7e9114411a9e5a17efdecbd83a68bcf087b6 /src/migration-scripts/https
parentd6902e6423ec78b5b99d96b6427ebee771ea6c38 (diff)
downloadvyos-1x-9babe4468dec43d2df20488bacd3877d77c42b35.tar.gz
vyos-1x-9babe4468dec43d2df20488bacd3877d77c42b35.zip
wwan: T9388: apply a static bearer's address/gateway/DNS directly
QMI raw-ip modems get their address, gateway and DNS from ModemManager as a "static" bearer instead of over a DHCP(v6) or Router Advertisement exchange, so "address dhcp", "address dhcpv6" and "ipv6 address autoconf" never produced a usable config and only worked for IPv4 by accident. Check the interface's connected bearer first. If its method for the family is static, apply it directly; if it is dhcp, or there is no bearer yet, fall through to the existing DHCP(v6) client / kernel SLAAC unchanged. - Address and DNS are applied from the bearer. DNS is registered with vyos-hostsd under the same dhcp-<if>/dhcpv6-<if> tags a real client uses. A DHCP(v6) client which was started while the bearer was still missing, including one which keeps restarting, is stopped before the settings are applied. - The default route is rendered into FRR as a tag 210 static route, the same way a DHCP one is. WWANIf records the gateway of the bearer in /run/vyos-wwan, which the new get_wwan_router() filter reads, and a new block in staticd.frr.j2 fed by get_wwan_interfaces() renders the IPv4 and IPv6 default routes. Distance, no-default-route and VRFs behave as for DHCP, also for an interface without "address dhcp". frrender notices a gateway change, and WWANIf reconciles FRR with vyos-frr-render.py whenever the recorded gateway changes, the way the dhclient lease hook does, so op-mode reconnect is covered as well. The state is written atomically, as the renderer reads it concurrently. - The address installed from the bearer is recorded in /run/vyos-wwan too. It is removed on reconnect, when the family is no longer configured and when the interface goes away, and nothing else on the interface is ever touched. - vyos-netlinkd applies the bearer again after it re-dials a lost session, as the new session can come back with a different address or gateway. A DHCP client used to pick that up on its own. What a previous session left behind is dropped for a family the new one does not supply, the configured DHCP(v6) client or SLAAC is started for it as a commit would, and an incomplete result is retried on the following reconcile passes for a while. - The bearer is picked by its connected status rather than bearers[0], and its config is polled briefly with wait_for() until it is no longer missing or a placeholder, since it can be populated slightly after the bearer reports connected.
Diffstat (limited to 'src/migration-scripts/https')
0 files changed, 0 insertions, 0 deletions