File size: 1,192 Bytes
f92da22 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
#!/usr/bin/env python3
"""
Configuration file for SFTP settings
"""
import os
from dotenv import load_dotenv
# Load environment variables
load_dotenv()
# SFTP Configuration
SFTP_CONFIG = {
'host': os.getenv('SFTP_HOST', '163.172.133.70'),
'port': int(os.getenv('SFTP_PORT', '2224')),
'username': os.getenv('SFTP_USERNAME', 'simplify'),
'password': os.getenv('SFTP_PASSWORD', 'V%40xi%24tD%40c2023'),
'remote_path': os.getenv('SFTP_REMOTE_PATH', '/simplify/model'),
'local_download_dir': os.getenv('LOCAL_MODELS_DIR', 'models')
}
# Transcription directory
TRANSCRIPTIONS_DIR = os.getenv('TRANSCRIPTIONS_DIR', 'transcriptions')
def get_sftp_config():
"""Return SFTP configuration dictionary."""
return SFTP_CONFIG.copy()
def print_sftp_config():
"""Print current SFTP configuration (without password)."""
config = get_sftp_config()
safe_config = config.copy()
safe_config['password'] = '***' if config['password'] else 'Not set'
print("🔧 SFTP Configuration:")
print("=" * 40)
for key, value in safe_config.items():
print(f" {key}: {value}")
print("=" * 40)
if __name__ == "__main__":
print_sftp_config()
|