mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-09-11 14:00:29 +00:00
a2b8940873
Implements REST API endpoints to enable automatic registration of temperature proxies during sensor-proxy installation. API endpoints: - POST /api/temperature-proxy/register - Accepts: hostname, proxy_url - Returns: authentication token - Finds matching PVE instance and configures proxy URL/token - No authentication required (called during installation) - DELETE /api/temperature-proxy/unregister?hostname=X - Removes proxy configuration from PVE instance - Requires admin authentication Implementation: - Uses config.ConfigPersistence for loading/saving nodes.enc - Matches PVE instances by hostname in Host field or ClusterEndpoints - Generates cryptographically secure random tokens (32 bytes, base64) - Atomic config updates (load → modify → save) Next step: Update install-sensor-proxy.sh to call registration API Related to #571