{"id":40418130,"url":"https://github.com/bloccooo/dbkp","last_synced_at":"2026-01-20T15:00:51.562Z","repository":{"id":281822669,"uuid":"946533007","full_name":"bloccooo/dbkp","owner":"bloccooo","description":"Simple tool to backup \u0026 restore databases","archived":false,"fork":false,"pushed_at":"2025-11-14T14:57:08.000Z","size":24633,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-11-14T15:25:39.478Z","etag":null,"topics":["backup","cli","db","gui","postgresql","restore","s3","storage"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bloccooo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-03-11T09:39:46.000Z","updated_at":"2025-11-14T14:57:12.000Z","dependencies_parsed_at":"2025-04-23T16:41:29.705Z","dependency_job_id":"a674ead7-dd75-4ecb-85aa-a2c720b7af6e","html_url":"https://github.com/bloccooo/dbkp","commit_stats":null,"previous_names":["vpr-group/vprs3bkp","vpr-group/vprdbbkp","vpr-group/dbkp","bloccooo/dbkp"],"tags_count":28,"template":false,"template_full_name":null,"purl":"pkg:github/bloccooo/dbkp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bloccooo%2Fdbkp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bloccooo%2Fdbkp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bloccooo%2Fdbkp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bloccooo%2Fdbkp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bloccooo","download_url":"https://codeload.github.com/bloccooo/dbkp/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bloccooo%2Fdbkp/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28605916,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-20T14:45:23.139Z","status":"ssl_error","status_checked_at":"2026-01-20T14:44:16.929Z","response_time":117,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["backup","cli","db","gui","postgresql","restore","s3","storage"],"created_at":"2026-01-20T15:00:29.622Z","updated_at":"2026-01-20T15:00:51.494Z","avatar_url":"https://github.com/bloccooo.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DB Backup - Database Backup \u0026 Restore Utility\n\nA simple tool for backing up databases to various cloud storage providers or local filesystems.\n\nDesigned to make database migrations easier, this project streamlines copying, backup, and restoration operations. It consists of a **library** and a **CLI tool** that can be used both as a command-line interface for server automation and through an interactive **TUI (Terminal User Interface)** for everyday development tasks like pulling production data into your local environment.\n\n**Important Note:** This is a side project used currently as an internal tool. It is not an industrial-grade solution. It only provides logical backup for the moment and might struggle with massive databases. Works great for development, testing, and smaller projects, but maybe don't bet your mission-critical production systems on it just yet...\n\nIf you need more advanced tools please check [Barman](https://pgbarman.org) or [pgbackrest](https://pgbackrest.org).\n\n## Installation\n\n### Quick Installation\n\n#### Linux\n\n```bash\ncurl -sSL https://raw.githubusercontent.com/bloccooo/dbkp/main/install-cli.sh | sudo bash\n```\n\n#### macOS\n\n```bash\ncurl -sSL https://raw.githubusercontent.com/bloccooo/dbkp/main/install-cli.sh | bash\n```\n\nNote: macOS users may need to remove `sudo` depending on their permission settings.\n\n### Install from Source (requires Rust toolchain)\n\n```bash\n# Clone the repository\ngit clone https://github.com/bloccooo/dbkp.git\ncd dbkp\n\n# Build the project\ncd cli\ncargo build --release\n\n# Install the binary\nsudo cp target/release/dbkp /usr/local/bin/dbkp\n```\n\n## TUI (Terminal User Interface)\n\nThe CLI tool includes an interactive TUI mode that provides a visual, menu-driven interface for managing backups and databases. The TUI offers the same functionality as the command-line interface with an intuitive, user-friendly experience.\n\n### Launching the TUI\n\nSimply run `dbkp` without any arguments to launch the TUI:\n\n```bash\ndbkp\n```\n\nThe TUI provides:\n\n- Visual database configuration\n- Storage setup with validation\n- Backup and restore operations\n- Navigation through menus\n\nYou can exit the TUI at any time using `esc`.\n\n## CLI Documentation\n\nFor detailed CLI usage, commands, parameters, and examples, see the [CLI Documentation](/cli/README.md).\n\nThe CLI tool supports multiple usage modes:\n\n- **TUI Mode**: Interactive terminal user interface (launch with `dbkp`)\n- **Direct Parameters**: For command-line control for automation\n\n## Features\n\n### Database Support\n\n- **PostgreSQL**: Backup and restore support\n- **Version Detection**: Automatic PostgreSQL version detection and compatibility\n\n### Storage Backends\n\n- **S3-Compatible Storage**: Amazon S3, MinIO, DigitalOcean Spaces, and other S3-compatible providers\n- **Local Filesystem**: Store backups on local or network-mounted filesystems\n\n### Backup \u0026 Restore Operations\n\n- **Streaming Architecture**: Memory-efficient streaming for large databases\n- **Logical Backups**: Full schema and data backup using `pg_dump`\n\n### User Experience\n\n- **TUI Mode**: Interactive terminal user interface for visual management\n\n### Automation \u0026 Integration\n\n- **CLI Automation**: Command-line interface for scripts and CI/CD\n- **Cron Job Ready**: Designed for scheduled backup operations\n- **Docker Compatible**: Works in containerized environments\n\n## Quick Start Example\n\n```bash\n# TUI mode (recommended for first-time users)\ndbkp\n\n# Command-line backup to S3\ndbkp backup \\\n  --database myapp \\\n  --host localhost \\\n  --username dbuser \\\n  --storage-type s3 \\\n  --bucket my-backups \\\n  --endpoint https://s3.amazonaws.com\n\n# Restore latest backup\ndbkp restore \\\n  --database myapp \\\n  --storage-type s3 \\\n  --bucket my-backups \\\n  --latest\n```\n\n## Architecture\n\nThe project is organized into two main components:\n\n- **Core Library** (`/core`): The `dbkp-core` library containing database connections, backup/restore logic, and storage backends. This can be used as a dependency in other Rust projects.\n- **CLI Tool** (`/cli`): The `dbkp` command-line tool that provides:\n  - **TUI Mode**: Interactive terminal user interface for visual management\n  - **Command-Line Mode**: Direct commands for automation and scripting\n\n## Use Cases\n\n### Development \u0026 Testing\n\n- Pull production data to local development environments\n- Create test data snapshots for consistent testing\n- Quick database migrations between environments\n\n### Small to Medium Production\n\n- Automated daily/weekly backups with retention policies\n- Database migrations and deployments\n- Disaster recovery for smaller applications\n\n## Limitations\n\n- **Logical Backups Only**: Does not support physical/binary backups\n- **Single Database Focus**: Optimized for individual database operations\n- **Not Industrial-Grade**: Suitable for development and smaller to medium production use cases\n- **PostgreSQL Focused**: Currently optimized primarily for PostgreSQL\n\nFor enterprise-grade solutions with physical backups, point-in-time recovery, and high-availability features, consider [Barman](https://pgbarman.org) or [pgbackrest](https://pgbackrest.org).\n\n## License\n\nMIT License - see LICENSE file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbloccooo%2Fdbkp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbloccooo%2Fdbkp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbloccooo%2Fdbkp/lists"}