remove hard coded directories
This commit is contained in:
@@ -11,8 +11,8 @@ from openvpn_manager import establish_vpn_connection, is_vpn_active, disconnect_
|
|||||||
|
|
||||||
# Variables
|
# Variables
|
||||||
CREDENTIAL_FILE = "nord.creds"
|
CREDENTIAL_FILE = "nord.creds"
|
||||||
OVPN_DIR = "/root/nordvpn/ovpn_configs/ovpn_tcp"
|
OVPN_DIR = "ovpn_configs/ovpn_tcp"
|
||||||
LOG_FILE = "/root/nordvpn/openvpn.log"
|
LOG_FILE = "openvpn.log"
|
||||||
RESULT_FILE = "vpnlist.txt"
|
RESULT_FILE = "vpnlist.txt"
|
||||||
|
|
||||||
# Check for debug flag
|
# Check for debug flag
|
||||||
@@ -27,7 +27,7 @@ def debug_print(message):
|
|||||||
# Open the log file in append mode if not in debug mode
|
# Open the log file in append mode if not in debug mode
|
||||||
log_file = None # Define log_file in the global scope
|
log_file = None # Define log_file in the global scope
|
||||||
if not DEBUG_MODE:
|
if not DEBUG_MODE:
|
||||||
log_file = open('/root/nordvpn/nord-checker.log', 'a')
|
log_file = open('nord-checker.log', 'a')
|
||||||
# Redirect stdout and stderr to the log file
|
# Redirect stdout and stderr to the log file
|
||||||
sys.stdout = log_file
|
sys.stdout = log_file
|
||||||
sys.stderr = log_file
|
sys.stderr = log_file
|
||||||
|
|||||||
Reference in New Issue
Block a user