refactor sql, logging, failure mgmt

This commit is contained in:
2024-09-05 19:39:15 -05:00
parent ff7e21d9b3
commit c7bd23977c
4 changed files with 146 additions and 66 deletions

View File

@@ -17,7 +17,7 @@ def establish_vpn_connection(ovpn_file, credential_file, log_file):
# Establish VPN connection (capture stdout and stderr)
openvpn_command = ["openvpn", "--config", ovpn_file,
"--auth-user-pass", credential_file, "--daemon",
"--log-append", log_file, "--verb", "3"]
"--log-append", log_file, "--verb", "0", "--flush-log"] # Added --flush-log
process = subprocess.Popen(openvpn_command,
stdin=subprocess.PIPE,