A Command Line Tool to Backup and Restore SQLite, MySQL and PostgreSQL!
Project description
Gulper
Gulper is a powerful and flexible command-line utility designed for backing up and restoring SQLite, MySQL, and PostgreSQL databases. It offers a range of features to streamline database management tasks, including scheduled backups, multiple storage options, and easy restoration.
Features
Multi-Database Support: Backup and restore SQLite, MySQL, and PostgreSQL databases.
Flexible Storage Options: Store backups locally or in cloud storage (AWS S3, DigitalOcean Spaces).
Scheduled Backups: Automate backups using cron-like expressions.
Point-in-Time Recovery: Restore databases to a specific point in time.
Compression: Reduce backup size with built-in compression options.
Retention Policies: Automatically manage backup retention periods.
Logging: Comprehensive logging of all backup and restore activities.
Installation
To install gulper, use the following command
$ pip install gulper
Configuration
Gulper uses a YAML configuration file to manage settings. By default, it looks for the configuration at /etc/config.yaml. You can specify a different path using the --config option.
Example configuration:
temp_dir: /tmp
state_file: /etc/gulper.db
logging:
level: error
handler: console
path: ~
event:
retention: 1 month
storage:
local_01:
type: local
path: /opt/backups/
aws_s3_01:
type: s3
access_key_id: your_access_key_id
secret_access_key: your_secret_access_key
bucket_name: your_bucket_name
region: your_region
path: /
do_s3_01:
type: s3
access_key_id: your_access_key_id
secret_access_key: your_secret_access_key
endpoint_url: https://nyc3.digitaloceanspaces.com
bucket_name: your_bucket_name
region: nyc3
path: /team_name/db_backups
schedule:
hourly:
expression: 0 * * * *
database:
db01:
type: mysql
host: localhost
username: root
password: your_password
port: 3306
database:
- db01
- db02
storage:
- local_01
schedule: hourly
options:
quote-names: True
quick: True
add-drop-table: True
add-locks: True
allow-keywords: True
disable-keys: True
extended-insert: True
single-transaction: True
create-options: True
comments: True
skip-ssl: True
no-tablespaces: True
net_buffer_length: 16384
retention: 3 months
db02:
type: postgresql
host: localhost
username: root
password: your_password
database: db01
storage:
- aws_s3_01
schedule: hourly
retention: 7 days
db03:
type: sqlite
path: /opt/app/opswork.db
storage:
- aws_s3_01
schedule: hourly
retention: 1 year
Usage
Backup Commands
List backups: gulper [--config PATH] backup list [--db DB] [--since SINCE] [--json]
Run backup: gulper [--config PATH] backup run DB [--json]
Get backup details: gulper [--config PATH] backup get BACKUP_ID [--json]
Delete backup: gulper [--config PATH] backup delete BACKUP_ID [--json]
Restore Commands
Restore from backup: gulper [--config PATH] restore run BACKUP_ID [--json]
Restore specific database: gulper [--config PATH] restore db DB [--json]
Cron Command
Run scheduled backups: gulper [--config PATH] cron [--daemon]
Event Command
List events: gulper [--config PATH] event list [--db DB] [--since SINCE] [--json]
Examples
Backup a database (MySQL or SQLite or PostgreSQL):
$ gulper --config config.yaml backup run $dbName
Restore a database from a specific backup or the latest db backup
$ gulper --config config.yaml restore run $backupId
$ gulper --config config.yaml restore db $dbName
List all backups or for a specific database:
$ gulper --config config.yaml backup list
$ gulper --config config.yaml backup list --json
$ gulper --config config.yaml backup list --db $dbName
$ gulper --config config.yaml backup list --db $dbName --since "3 hours ago"
Run scheduled backups in daemon mode:
$ gulper --config config.yaml cron --daemon
To get a list of events.
$ gulper --config config.yaml event list
$ gulper --config config.yaml event list --db $dbName --since "1 hour ago"
$ gulper --config config.yaml event list --json
Versioning
For transparency into our release cycle and in striving to maintain backward compatibility, Tyran is maintained under the Semantic Versioning guidelines and release process is predictable and business-friendly.
See the Releases section of our GitHub project for changelogs for each release version of Tyran. It contains summaries of the most noteworthy changes made in each release. Also see the Milestones section for the future roadmap.
Bug tracker
If you have any suggestions, bug reports, or annoyances please report them to our issue tracker at https://github.com/Clivern/Gulper/issues
Security Issues
If you discover a security vulnerability within Gulper, please send an email to hello@clivern.com
Contributing
We are an open source, community-driven project so please feel free to join us. see the contributing guidelines for more details.
License
© 2025, Gulper. Released under MIT License.
Gulper is authored and maintained by Clivern.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gulper-0.0.16.tar.gz.
File metadata
- Download URL: gulper-0.0.16.tar.gz
- Upload date:
- Size: 84.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dd2af59dbf8a1e121662074552f702dadcf57af6b8340a8db31ebb3daa92bbf5
|
|
| MD5 |
ae788fa2d0b18ce41cc6eea3a1808ea0
|
|
| BLAKE2b-256 |
b7b97b44efb45ce8bbc069977b053ce41586dbd632cfb57cdb301e23aeee5022
|
File details
Details for the file gulper-0.0.16-py3-none-any.whl.
File metadata
- Download URL: gulper-0.0.16-py3-none-any.whl
- Upload date:
- Size: 51.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
36d444d9ece0dc5defa0f4807e8082e44de4491abfee44046ae4d85e033007ad
|
|
| MD5 |
2554f366f22f200fb51f0bc6a3711871
|
|
| BLAKE2b-256 |
4e29791f2da13867e8b1d98a1c664aea6e28d2a0fbc9f726058fbac95ba67abc
|