lifebelt is small Typescript app that can back up different databases and upload them to an SFTP server in a unified manner. The most common use case is to run as a sidecar container in a Kubernetes pod thus giving the tool its nautical name.
Lifebelt can currently only back up the following DBMS:
- MySQL (Docker image:
- Couchbase (Docker image:
- CouchDB (Docker image:
Pull requests for additional providers are much welcome!
$ DEVELOPMENT=true ./build.sh # This will create the necessary docker images without trying to push them $ cd <provider-name> $ docker-compose up
To see a detailed list of options start a container passing the
$ docker run neoskop/lifebelt-mysql:latest -h
There are currently six different main commands that lifebelt can execute:
cron: Will run nightly backups
backup: Will create a backup immediately
test-backup: Will create a test backup without saving it
clean: Removes stale backups
restore: Restores the latest daily dump
providers: List all available providers
To set-up SFTP credentials and other config options, either supply them by environment variable (As seen in the
docker-compose.yml files) or by config file (Via
-c). To see which options are available, look at the config.ts and provider sources.
To release a new version ensure that the version was adjusted in the package.json and that a tag for this was version was created in the repository. Afterwards you just need to run
to create and push new docker images.
- Implement restoring
- Implement verification
- Add more providers
- Add k8s examples
- As a sidecar in a pod
googlecontainer/leader-elector/in a HA cluster
- As a CronJob resource
- Add warning for anomalies in sizes
This project is under the terms of the Apache License, Version 2.0. A copy of this license is included with the sources.