Files
play-life/list-dumps.sh
poignatov 7398918bc0
All checks were successful
Build and Push Docker Image / build-and-push (push) Successful in 57s
Release v1.1.0: Add Telegram and Todoist integrations UI
- Add telegram_integrations table to store bot token and chat_id
- Add Integrations tab with Todoist and Telegram integration screens
- Remove TELEGRAM_BOT_TOKEN and TELEGRAM_CHAT_ID from env variables
- All Telegram configuration now done through UI
- Telegram webhook registration happens when user saves bot token
- Rename TELEGRAM_WEBHOOK_BASE_URL to WEBHOOK_BASE_URL
2025-12-31 19:11:28 +03:00

36 lines
1.3 KiB
Bash
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/bin/bash
# Скрипт для просмотра списка доступных дампов
DUMP_DIR="database-dumps"
if [ ! -d "$DUMP_DIR" ]; then
echo "❌ Директория дампов не найдена: $DUMP_DIR"
exit 1
fi
echo "📦 Доступные дампы базы данных:"
echo ""
# Показываем дампы с информацией о размере и дате
if ls "$DUMP_DIR"/*.sql.gz 2>/dev/null | grep -q .; then
ls -lh "$DUMP_DIR"/*.sql.gz 2>/dev/null | awk '{
filename = $9
gsub(/.*\//, "", filename)
printf " %-40s %8s %s %s %s\n", filename, $5, $6, $7, $8
}'
echo ""
echo "Всего дампов: $(ls -1 "$DUMP_DIR"/*.sql.gz 2>/dev/null | wc -l | tr -d ' ')"
echo ""
echo "Для восстановления используйте:"
echo " ./restore-db.sh <имя_дампа.sql.gz> # В .env"
echo " ./restore-db.sh --env-file .env.prod <имя_дампа> # В указанный файл"
else
echo " (нет дампов)"
echo ""
echo "Для создания дампа используйте:"
echo " ./dump-db.sh # Из .env"
echo " ./dump-db.sh --env-file .env.prod [имя] # Из указанного файла"
fi