The Hub no longer asks a STUN server, a public DNS resolver or a "what
is my IP" service for the home IP address. The DDNS update asks Njal.la
to use the address the request comes from ("&auto"), reads back the
address Njal.la says it recorded and saves it to
/var/lib/secrets/external-ip. Njal.la is the only third party that
learns the address; it has to, to publish it.
- Add app/sovran_systemsos_web/ddns_update.py, installed as
/etc/sovran/ddns-update.py and run by sovran-ddns-update.service. It
runs curl --ipv4 without redirects, accepts only a public IPv4
address, and rewrites the file atomically and only when the address
changes. Stored "&a=${IP}" URLs are converted when they are used and
"&quiet" is dropped.
- Rewrite modules/core/njalla.nix around that runner and delete
modules/core/public-ip.nix. Setting a sovran_systemsOS.publicIP.*
option now fails with a message that says where the address comes
from. Activation removes the old scripts in /var/lib/sovran. The
existing external-ip file keeps working.
- server.py reads the saved address and starts
sovran-ddns-update.service after a domain is saved, instead of looking
the address up itself.
- Element calling uses sovran_systemsOS.elementCalling.externalIP if
set, otherwise the saved address, and fails with a clear message when
neither exists or the address is not public. It no longer falls back
to STUN. livekit-external-ip.path re-runs livekit-turn-setup and
starts LiveKit when the address changes.
- Add tests/test_ddns_update.py.
39 lines
1.1 KiB
Nix
Executable File
39 lines
1.1 KiB
Nix
Executable File
{ config, pkgs, lib, ... }:
|
|
|
|
{
|
|
imports = [
|
|
# ── Core (always loaded) ──────────────────────────────────
|
|
./core/roles.nix
|
|
./core/role-logic.nix
|
|
./core/caddy.nix
|
|
./core/njalla.nix
|
|
./core/ssh-bootstrap.nix
|
|
./core/tech-support.nix
|
|
./core/sovran_systemsos-desktop.nix
|
|
./core/sshd-localhost.nix
|
|
./core/sovran-hub.nix
|
|
./core/legacy-cleanup.nix
|
|
./core/remote-deploy.nix
|
|
./core/no-sleep.nix
|
|
./core/cpu-performance.nix
|
|
./core/local-domain-loopback.nix
|
|
|
|
# ── Always on (no flag) ───────────────────────────────────
|
|
./php.nix
|
|
./credentials.nix
|
|
|
|
# ── Services (default ON — disable in custom.nix) ─────────
|
|
./synapse.nix
|
|
./wordpress.nix
|
|
./nextcloud.nix
|
|
./vaultwarden.nix
|
|
./wallet-autoconnect.nix
|
|
|
|
# ── Features (default OFF — enable in custom.nix) ─────────
|
|
./haven.nix
|
|
./element-calling.nix
|
|
./rdp.nix
|
|
./sshd.nix
|
|
];
|
|
}
|