-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.py
More file actions
17 lines (15 loc) · 717 Bytes
/
config.py
File metadata and controls
17 lines (15 loc) · 717 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
import os
from dotenv import load_dotenv
load_dotenv()
class Config:
SECRET_KEY = os.environ.get('SECRET_KEY') or 'dev-secret-key-change-in-production'
# PostgreSQL Connection URI
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL') or 'postgresql://postgres:postgres@localhost/cipher-vault'
SQLALCHEMY_TRACK_MODIFICATIONS = False
UPLOAD_FOLDER = os.environ.get('UPLOAD_FOLDER') or 'uploads'
MAX_CONTENT_LENGTH = 16 * 1024 * 1024 # 16MB max limit
ALLOWED_EXTENSIONS = {
'txt', 'pdf', 'png', 'jpg', 'jpeg', 'gif', 'webp',
'c', 'cpp', 'py', 'rb', 'go', 'kt', 'java', 'js', 'html', 'css',
'php', 'cs', 'swift', 'rs', 'ts', 'sh', 'bat', 'zip', 'tar', 'gz'
}