1. EROFS: install.sh pre-writes DNS hijack config to dnsmasq-shared.d
since /etc may be read-only at runtime. dns-hijack.js gracefully
falls back to checking if config already exists.
2. Double WS: add _connectionStarted guard to prevent _proceedWithConnection
from being called twice (via event + hasInternet check).
3. Watchdog: move _startSdNotify() to start() beginning so READY=1
is sent immediately, not delayed until network is ready.
Made-with: Cursor
Killing all dnsmasq processes caused NetworkManager to detect its
hotspot dnsmasq died and tear down the hotspot (AP appears briefly
then disappears).
Now leverage NM's built-in dnsmasq-shared.d config directory:
write DNS hijack config before starting AP so NM's own dnsmasq
picks it up. No separate dnsmasq process needed.
Made-with: Cursor
After WiFi is configured and device reboots, NetworkManager needs
a few seconds to auto-connect to saved WiFi. Without waiting,
AP starts immediately and occupies wlan0, preventing NM reconnect.
- Add hasSavedWifiConnection() to check for saved WiFi profiles
- Wait up to 20s for NM auto-connect before falling back to AP
- First boot (no saved WiFi) still starts AP immediately
Made-with: Cursor
Redesign provisioning from one-shot blocking to persistent background manager:
- AP hotspot starts at boot regardless of eth0 status
- Captive portal runs alongside AP for WiFi configuration
- AP automatically shuts down only when WiFi STA connects
- WiFi drops at runtime -> AP auto-restarts
- WiFi connect fails -> AP auto-restarts for retry
- client.js no longer blocks on network; connects WS when ready
Made-with: Cursor
NetworkManager auto-starts its own dnsmasq when creating a hotspot,
which conflicts with our DNS-hijacking dnsmasq on the same interface.
Now kill ALL dnsmasq instances before starting ours.
Made-with: Cursor
Open network was not viable as nmcli generates random password by default.
Use a simple fixed password since the AP is only for short-lived provisioning.
Made-with: Cursor
- dns-hijack.js: replace `which` with multi-path search (/usr/sbin etc.)
since dnsmasq is often not in normal user PATH
- install.sh: auto-enable NetworkManager for WiFi provisioning
- install.sh: unblock WiFi rfkill at install time
- install.sh: create clawd-rfkill.service for persistent boot-time unlock
Made-with: Cursor