Store SQLite DB on remote host via SCP for persistence
Instead of syncing JSON files back, the SQLite DB itself is now the persistent store on the remote HAProxy host: - Startup: download remote DB via SCP (skip migration if exists) - After writes: upload local DB via SCP (WAL checkpoint first) - JSON sync removed (sync_servers_json, sync_certs_json deleted) New functions: - ssh_ops: remote_download_file(), remote_upload_file() via SCP - db: sync_db_to_remote(), _try_download_remote_db() Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -296,6 +296,7 @@ def patch_config_paths(temp_config_dir):
|
||||
SERVERS_FILE=temp_config_dir["servers_file"],
|
||||
CERTS_FILE=temp_config_dir["certs_file"],
|
||||
DB_FILE=temp_config_dir["db_file"],
|
||||
REMOTE_DB_FILE=temp_config_dir["db_file"],
|
||||
):
|
||||
# Patch health module which imports MAP_FILE and DB_FILE
|
||||
with patch.multiple(
|
||||
|
||||
Reference in New Issue
Block a user