Documentation
¶
Overview ¶
Package config manages proximo's persisted user configuration and the on-disk paths it uses (TLS material, the embedded stack, etc.).
Index ¶
Constants ¶
const ( // DefaultTLD is the default top-level domain used for local routing. // ".test" is reserved by RFC 6761 and never collides with mDNS (".local"). DefaultTLD = "test" // DNSPort is the loopback UDP host port the DNS server is published on. A // high port avoids any privileged bind to :53; 5353 is intentionally // avoided because macOS mDNSResponder (Bonjour) already binds it. DNSPort = 5354 // ObsHubPort is the loopback TCP host port the metrics hub is published on // (only when the observability profile is active) so the one-shot bootstrap // can reach the hub API directly, without depending on DNS/Traefik/TLS being // converged yet. A high, uncommon port avoids colliding with the hub's // default 8090. ObsHubPort = 48090 // InspectAPIPort is the loopback TCP host port the Inspection hop publishes // its read API on, so `proximo errors` can reach it. The proxy side of the // hop is never published: only Traefik talks to it, over the stack network. InspectAPIPort = 48091 )
Variables ¶
This section is empty.
Functions ¶
func DataDir ¶ added in v0.3.0
DataDir returns (creating if needed) the directory holding the stack's bind-mounted runtime data (Traefik routes/certs, Beszel metrics). It is the host side of the data bind mounts the materialized compose declares.
func HomePath ¶ added in v0.4.0
HomePath resolves the state-home path ($HOME/.proximo) without creating it, so callers that only need the location (RemoveHome, `config ca-path`) don't trigger side effects.
func NormalizeTLD ¶
NormalizeTLD validates and normalizes a user-supplied TLD: it strips a leading dot, lowercases, enforces a single DNS label, and rejects reserved values.
func RemoveHome ¶ added in v0.3.0
func RemoveHome() error
RemoveHome deletes the entire ~/.proximo state home (CA, secret, config, materialized stack, and bind-mounted data). uninstall calls it after the stack is down and host trust/resolver are reversed, for a full reversal. It resolves the path without creating it.
func TLDWarning ¶ added in v0.12.0
TLDWarning returns advice for a TLD with no reservation behind it, or "" for a reserved one. It never rejects: the choice is the user's, but a label someone else may own shadows every public name under it.