feat: add backups feature

This commit is contained in:
3252a8
2026-05-27 13:53:30 +03:00
parent e90988ea5c
commit 3aede8fe95
55 changed files with 3032 additions and 70 deletions
+42
View File
@@ -871,6 +871,7 @@
"admin_nav_system": "System",
"admin_nav_tariffs": "Tariffs",
"admin_nav_themes": "Themes",
"admin_nav_backups": "Backups",
"admin_nav_settings": "Settings",
"admin_section_stats_title": "Dashboard",
"admin_section_stats_subtitle": "Audience, revenue, Remnawave panel, and recent payments",
@@ -890,8 +891,36 @@
"admin_section_tariffs_subtitle": "Sales catalog, periods, packages, and limits",
"admin_section_themes_title": "Web App themes",
"admin_section_themes_subtitle": "Colors, fonts, and Mini App appearance",
"admin_section_backups_title": "Backups",
"admin_section_backups_subtitle": "Archives, uploads, and database/compose restore",
"admin_section_settings_title": "App Settings",
"admin_section_settings_subtitle": "Overrides for .env, applied instantly",
"admin_backups_load_failed": "Failed to load backups",
"admin_backups_upload_done": "Archive uploaded",
"admin_backups_upload_failed": "Failed to upload archive",
"admin_backups_select_archive": "Select an archive",
"admin_backups_select_target": "Select what to restore",
"admin_backups_restore_done": "Restore completed",
"admin_backups_restore_failed": "Restore failed",
"admin_backups_col_archive": "Archive",
"admin_backups_col_created": "Created",
"admin_backups_col_size": "Size",
"admin_backups_col_contents": "Contents",
"admin_backups_col_warnings": "Warnings",
"admin_backups_target_database": "Database",
"admin_backups_target_compose": "compose folder",
"admin_backups_restore_confirm": "Start restore from {name}: {components}?",
"admin_backups_uploading": "Uploading...",
"admin_backups_upload": "Upload archive",
"admin_backups_dir": "Directory",
"admin_backups_restore_title": "Restore",
"admin_backups_last_restore_done": "Done",
"admin_backups_restoring": "Restoring...",
"admin_backups_restore_run": "Start",
"admin_backups_pre_restore_snapshot": "Current compose folder was saved before replacement: {path}",
"admin_backups_empty": "No archives yet",
"admin_backups_badge_db": "DB",
"admin_backups_badge_compose": "Compose",
"admin_filter_all": "All",
"admin_filter_not_banned": "Not banned",
"admin_filter_banned": "Banned",
@@ -975,6 +1004,7 @@
"admin_settings_section_trial": "Trial",
"admin_settings_section_referral": "Referral program",
"admin_settings_section_notifications": "Notifications",
"admin_settings_section_backups": "Backups",
"admin_settings_section_devices": "Devices",
"admin_settings_section_support": "Support",
"admin_settings_subsection_common": "Common",
@@ -1553,6 +1583,18 @@
"admin_settings_field_support_ticket_max_subject_length_description": "Maximum number of characters in a ticket subject.",
"admin_settings_field_support_ticket_rate_limit_per_hour_label": "Ticket limit per hour",
"admin_settings_field_support_ticket_rate_limit_per_hour_description": "How many new tickets a user can create per hour. 0 means unlimited.",
"admin_settings_field_backup_enabled_label": "Backups enabled",
"admin_settings_field_backup_enabled_description": "The worker periodically builds a ZIP archive and sends it to Telegram.",
"admin_settings_field_backup_chat_id_label": "Backup chat ID",
"admin_settings_field_backup_chat_id_description": "Where ZIP archives are sent. Falls back to LOG_CHAT_ID when empty.",
"admin_settings_field_backup_thread_id_label": "Backup thread ID",
"admin_settings_field_backup_thread_id_description": "Optional topic/thread ID. Falls back to LOG_THREAD_ID when empty.",
"admin_settings_field_backup_interval_seconds_label": "Backup period (sec.)",
"admin_settings_field_backup_interval_seconds_description": "Default is 3600: run on the hour boundary (12:00, 13:00, etc.).",
"admin_settings_field_backup_local_retention_label": "Archives to keep",
"admin_settings_field_backup_local_retention_description": "How many latest ZIP archives to keep in data/backups on the server.",
"admin_settings_field_backup_compose_enabled_label": "Include compose folder",
"admin_settings_field_backup_compose_enabled_description": "Adds a /app/compose-source snapshot. If the folder is not mounted, the DB backup is still created.",
"admin_settings_field_my_devices_section_enabled_label": "My Devices Section Enabled",
"admin_settings_field_user_hwid_device_limit_label": "User HWID Device Limit",
"admin_settings_field_user_traffic_limit_gb_label": "User Traffic Limit Gb",
+42
View File
@@ -871,6 +871,7 @@
"admin_nav_system": "Система",
"admin_nav_tariffs": "Тарифы",
"admin_nav_themes": "Темы",
"admin_nav_backups": "Бэкапы",
"admin_nav_settings": "Настройки",
"admin_section_stats_title": "Дашборд",
"admin_section_stats_subtitle": "Аудитория, доходы, панель Remnawave и последние платежи",
@@ -890,8 +891,36 @@
"admin_section_tariffs_subtitle": "Каталог продаж, периоды, пакеты и лимиты",
"admin_section_themes_title": "Темы Web App",
"admin_section_themes_subtitle": "Цвета, шрифты и темы оформления Mini App",
"admin_section_backups_title": "Бэкапы",
"admin_section_backups_subtitle": "Архивы, загрузка и восстановление БД/compose",
"admin_section_settings_title": "Настройки приложения",
"admin_section_settings_subtitle": "Оверрайды над .env, применяются мгновенно",
"admin_backups_load_failed": "Не удалось загрузить бэкапы",
"admin_backups_upload_done": "Архив загружен",
"admin_backups_upload_failed": "Не удалось загрузить архив",
"admin_backups_select_archive": "Выберите архив",
"admin_backups_select_target": "Выберите, что восстановить",
"admin_backups_restore_done": "Восстановление завершено",
"admin_backups_restore_failed": "Не удалось восстановить",
"admin_backups_col_archive": "Архив",
"admin_backups_col_created": "Создан",
"admin_backups_col_size": "Размер",
"admin_backups_col_contents": "Состав",
"admin_backups_col_warnings": "Предупреждения",
"admin_backups_target_database": "БД",
"admin_backups_target_compose": "compose-папка",
"admin_backups_restore_confirm": "Запустить восстановление из {name}: {components}?",
"admin_backups_uploading": "Загрузка...",
"admin_backups_upload": "Загрузить архив",
"admin_backups_dir": "Каталог",
"admin_backups_restore_title": "Восстановление",
"admin_backups_last_restore_done": "Готово",
"admin_backups_restoring": "Восстановление...",
"admin_backups_restore_run": "Запустить",
"admin_backups_pre_restore_snapshot": "Текущая compose-папка сохранена перед заменой: {path}",
"admin_backups_empty": "Архивов пока нет",
"admin_backups_badge_db": "БД",
"admin_backups_badge_compose": "Compose",
"admin_filter_all": "Все",
"admin_filter_not_banned": "Не забанены",
"admin_filter_banned": "Забанены",
@@ -975,6 +1004,7 @@
"admin_settings_section_trial": "Триал",
"admin_settings_section_referral": "Реферальная программа",
"admin_settings_section_notifications": "Уведомления",
"admin_settings_section_backups": "Бэкапы",
"admin_settings_section_devices": "Устройства",
"admin_settings_section_support": "Поддержка",
"admin_settings_subsection_common": "Общие",
@@ -1553,6 +1583,18 @@
"admin_settings_field_support_ticket_max_subject_length_description": "Максимальное количество символов в теме тикета.",
"admin_settings_field_support_ticket_rate_limit_per_hour_label": "Лимит тикетов в час",
"admin_settings_field_support_ticket_rate_limit_per_hour_description": "Сколько новых тикетов пользователь может создать за час. 0 — без лимита.",
"admin_settings_field_backup_enabled_label": "Бэкапы включены",
"admin_settings_field_backup_enabled_description": "Worker будет периодически собирать ZIP-архив и отправлять его в Telegram.",
"admin_settings_field_backup_chat_id_label": "ID чата для бэкапов",
"admin_settings_field_backup_chat_id_description": "Куда отправлять ZIP-архивы. Если пусто, используется LOG_CHAT_ID.",
"admin_settings_field_backup_thread_id_label": "ID треда для бэкапов",
"admin_settings_field_backup_thread_id_description": "Необязательный topic/thread ID. Если пусто, используется LOG_THREAD_ID.",
"admin_settings_field_backup_interval_seconds_label": "Период бэкапов (сек.)",
"admin_settings_field_backup_interval_seconds_description": "По умолчанию 3600: запуск на границе часа (12:00, 13:00 и т.д.).",
"admin_settings_field_backup_local_retention_label": "Сколько архивов хранить",
"admin_settings_field_backup_local_retention_description": "Сколько последних ZIP-архивов оставлять в data/backups на сервере.",
"admin_settings_field_backup_compose_enabled_label": "Добавлять compose-папку",
"admin_settings_field_backup_compose_enabled_description": "Добавляет snapshot /app/compose-source. Если папка не смонтирована, бэкап БД все равно будет создан.",
"admin_settings_field_my_devices_section_enabled_label": "Раздел «Мои устройства»",
"admin_settings_field_user_hwid_device_limit_label": "Лимит устройств по умолчанию (0 = ∞)",
"admin_settings_field_user_traffic_limit_gb_label": "Лимит трафика пользователя (ГБ)",