1. Fix order: Save to disk FIRST, then update HAProxy - Prevents inconsistency if HAProxy update succeeds but disk write fails - Data is preserved correctly on restart 2. Add IPv6 support - Use Python ipaddress module instead of regex - Now accepts both IPv4 and IPv6 addresses 3. Extract atomic_write_file() helper - Eliminates duplicated code in save_map_file, save_servers_config, haproxy_save_state - Single source of truth for atomic file operations Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
46 KiB
46 KiB