27 lines
1.1 KiB
Python
27 lines
1.1 KiB
Python
from sqlalchemy import Boolean, Column, Integer, String, Text
|
|
|
|
from app.db.session import Base
|
|
|
|
|
|
class GlobalSettings(Base):
|
|
__tablename__ = "global_settings"
|
|
|
|
id = Column(Integer, primary_key=True)
|
|
backup_retention_days = Column(Integer, default=7)
|
|
log_retention_days = Column(Integer, default=7)
|
|
export_cron = Column(String(64), default="")
|
|
binary_cron = Column(String(64), default="")
|
|
retention_cron = Column(String(64), default="")
|
|
enable_auto_export = Column(Boolean, default=False)
|
|
connection_test_interval_minutes = Column(Integer, default=0)
|
|
global_ssh_key = Column(Text, nullable=True)
|
|
pushover_token = Column(String(255), nullable=True)
|
|
pushover_userkey = Column(String(255), nullable=True)
|
|
notify_failures_only = Column(Boolean, default=True)
|
|
smtp_host = Column(String(255), nullable=True)
|
|
smtp_port = Column(Integer, default=587)
|
|
smtp_login = Column(String(255), nullable=True)
|
|
smtp_password = Column(String(255), nullable=True)
|
|
smtp_notifications_enabled = Column(Boolean, default=False)
|
|
recipient_email = Column(String(255), nullable=True)
|