Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions packages/omamobile-device-cheetah/test/all
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,20 @@ pass "build stays inside the package directory"
./build "$tmp/build" || fail "C tools compile"
pass "C tools compile"

# The host is a fallback gateway; Wi-Fi DHCP (metric 600) wins.
python3 - <<'ROUTE'
import configparser
from pathlib import Path
p = configparser.ConfigParser(strict=False)
p.read('vendor/systemd/network/20-usb-gadget.network')
assert p['Match']['Name'] == 'usb0'
assert p['Network']['Address'] == '172.16.42.1/24'
assert 'Gateway' not in p['Network']
assert p['Route']['Gateway'] == '172.16.42.2'
assert p['Route'].getint('Metric') == 1024
ROUTE
pass "USB gateway is a fallback route in the Route section"

# omamobile-bootctl against a synthetic devinfo: dump works, and a dry run
# of mark-successful plans exactly one flag byte and writes nothing
python3 - "$tmp/devinfo" <<'PY'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,19 @@
# Omarchy Mobile: USB networking to the host. The initramfs sets up the USB
# gadget (CDC NCM) before handing over to Arch; this gives it an address.
# The host shares its internet over this link (NetworkManager "shared"
# mode on 172.16.42.2), so it is also the gateway. DNS goes to public resolvers.
# mode on 172.16.42.2), so it is also a gateway, but only as a fallback:
# metric 1024 lets Wi-Fi's DHCP route (NetworkManager, metric 600) win when it is
# up. With metric 0 here, internet traffic went to the host while Wi-Fi was
# connected (2026-10-30). DNS goes to public resolvers.
[Match]
Name=usb0

[Network]
Address=172.16.42.1/24
Gateway=172.16.42.2
DNS=1.1.1.1
DNS=9.9.9.9
ConfigureWithoutCarrier=yes

[Route]
Gateway=172.16.42.2
Metric=1024
2 changes: 1 addition & 1 deletion packages/omamobile-device-cheetah/version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.1.33
0.1.34