db-backup

Automate PostgreSQL database backups, restores, and cleanup with timestamped gzip files.

1|Updated Apr 6, 2026
One-click install
npx skills add https://github.com/zhu637882-stack/jiaoyi --skill db-backup-zhu637882-stack
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: db-backup
Source: https://github.com/zhu637882-stack/jiaoyi/tree/main/qoder-config-backup/skills/db-backup
Command: npx skills add https://github.com/zhu637882-stack/jiaoyi --skill db-backup-zhu637882-stack

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

自动化数据库备份与恢复,并提供自动清理旧备份的能力,减少手动维护时间和避免数据丢失风险。

Core Features & Use Cases

  • 全量备份与按表备份支持,快速恢复到指定时间点。
  • 自动清理7天前备份,控制存储成本。
  • 适用于 PostgreSQL 数据库,支持通过环境变量配置数据库、用户名和备份目录等。

Quick Start

加载环境变量后执行备份脚本,以创建带时间戳的数据库备份。

Frequently Asked Questions about db-backup

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate PostgreSQL backup and restore tasks?

Automating PostgreSQL backup and restore uses scripts to create timestamped, gzip-compressed full or table-specific backups while automatically cleaning up old files to prevent data loss and control storage costs.

Does PostgreSQL backup automation support table-specific restores?

PostgreSQL backup automation supports table-specific backups, allowing you to quickly restore individual tables or perform full database recovery to a specific timestamp for rapid disaster recovery scenarios.

How do I configure environment variables for a PostgreSQL backup script?

Configuring environment variables for a PostgreSQL backup script requires defining your database name, username, and target backup directory before execution, ensuring the automated process correctly targets your deployment and saves timestamped files.

What is the best way to clean up old PostgreSQL database backups?

The best way to clean up old PostgreSQL database backups is through automated scripting that enforces the deletion of archives older than seven days, effectively controlling storage costs without requiring manual maintenance.

Can I use gzip compression for PostgreSQL database backups?

You can use gzip compression for PostgreSQL database backups to reduce file size, combining it with timestamped naming and automated old-backup cleanup to maintain an efficient and cost-effective disaster recovery archive.