Add phone hotspot uplink

Prefer a configured phone hotspot for outbound synchronization, preserve secure write-only credentials, and recover through home WiFi or the local Pi hotspot.

Co-authored-by: Copilot <[email protected]>
This commit is contained in:
Mathieu Moran
2026-08-09 22:48:11 -04:00
co-authored by Copilot
parent 5c707fe295
commit cdb032b888
17 changed files with 1211 additions and 88 deletions
+38
View File
@@ -37,6 +37,44 @@
</div>
</div>
<div class="card shadow mb-4">
<div class="card-header py-3">
<p class="text-primary m-0 fw-bold">Phone hotspot internet</p>
</div>
<div class="card-body">
<p id="uplink-status" class="mb-3">Checking network mode...</p>
<p id="last-phone-address" class="small mb-3" hidden>
Last phone-network address:
<a id="last-phone-address-link" href="#"></a>
<span class="text-muted">(DHCP may change it after reconnecting.)</span>
</p>
<div class="row g-3">
<div class="col-md-6">
<label class="form-label" for="phone-hotspot-ssid">Phone hotspot name</label>
<input class="form-control" id="phone-hotspot-ssid" maxlength="32" autocomplete="off">
</div>
<div class="col-md-6">
<label class="form-label" for="phone-hotspot-password">Phone hotspot password</label>
<input class="form-control" id="phone-hotspot-password" type="password" minlength="8" maxlength="63" autocomplete="new-password">
</div>
</div>
<div id="uplink-message" class="alert mt-3 mb-0" role="status" hidden></div>
<div class="d-flex flex-wrap gap-2 mt-3">
<button class="btn btn-primary" id="phone-hotspot-save" type="button">Save hotspot</button>
<button class="btn btn-outline-primary" id="phone-hotspot-connect" type="button" disabled>Wait for hotspot</button>
<button class="btn btn-outline-danger" id="phone-hotspot-remove" type="button" disabled>Remove hotspot</button>
</div>
<p class="form-text mb-0 mt-3">
Save while the phone is still connected to the Pi/home WiFi. Then select
<strong>Wait for hotspot</strong> and enable the phone hotspot within two minutes.
The password is write-only and is never returned here. This page may briefly close
while networks switch. Some phones do not resolve <strong>yaris.local</strong> for
tethered clients; use the last direct address shown above when needed. If the phone
hotspot never appears, the Pi restores home WiFi or its local hotspot.
</p>
</div>
</div>
<div class="card shadow mb-4">
<div class="card-header py-3">
<p class="text-primary m-0 fw-bold">Cellular trip-log fallback</p>