mdump is a simple database backup manager.
The simple way to install an application is using Docker
docker build -t mdump:latest .
mdump is written in the Go programming language and you need at least Go version 1.16. Mdump may also work with older versions of Go, but that’s not supported. In order to build mdump from source, execute the following steps:
$ git clone https://github.com/myarik/mdump.git
[...]
$ cd mdump
$ go build -o mdump -ldflags "-s -w" ./main.go
The binary requires database dump tools (pg_dump, etc...)
Backing up databases to the local storage
$ /usr/bin/mdump pgdump local --pg_uri postgresql://[user[:password]@][netloc][:port] --path /backup
Backing up databases to an Amazon S3 bucket. You must first set up the following environment variables with the credentials.
$ export AWS_ACCESS_KEY_ID=<MY_ACCESS_KEY>
$ export AWS_SECRET_ACCESS_KEY=<MY_SECRET_ACCESS_KEY>
$ export AWS_REGION=eu-west-2
Backing up databases to the S3
$ /usr/bin/mdump pgdump s3 --pg_uri postgresql://[user[:password]@][netloc][:port] --aws-bucket bucket_name --aws-bucket-key bucket_key
- PostgreSQL