https://github.com/skandragon/postgresql-simple-backup
A simple backup system for a postgresql database, inside a Docker container.
https://github.com/skandragon/postgresql-simple-backup
postgresql postgresql-backup
Last synced: 2 months ago
JSON representation
A simple backup system for a postgresql database, inside a Docker container.
- Host: GitHub
- URL: https://github.com/skandragon/postgresql-simple-backup
- Owner: skandragon
- License: apache-2.0
- Created: 2020-05-22T03:01:01.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2024-02-09T02:51:58.000Z (over 2 years ago)
- Last Synced: 2025-07-04T00:08:32.417Z (12 months ago)
- Topics: postgresql, postgresql-backup
- Language: Shell
- Size: 13.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# postgresql-simple-backup
Docker Hub: https://hub.docker.com/repository/docker/skandragon/postgresql-simple-backup
Git: https://github.com/skandragon/postgresql-simple-backup
Simple backup strategy for PostgreSQL, useful for simple installations or non-critical systems.
`postgresql-simple-backup` is a Docker container which can run
once, or loop internally, doing backups of selected database
on a target host.
# Configuration
Any defaults are shown, but check `run.sh` just to make sure they are in sync.
All configuration parameters are provided via environment variables.
## Connection
These connection parameters must be defined. All databases backed up will share this common configuration.
```sh
PGHOST=
PGPORT=5432
PGUSER=
PGPASSWORD=
```
## Databases
A space-separated list of databases to back up.
```sh
DATABASES=
```
## Cleanup
Age, in days, when older backups will be removed. If empty, no
expiring will happen.
```sh
BACKUP_EXPIRE_DAYS=14
```
If defined as an empty string, it will disable expiration.
## Destination
Location where backups will be written. This should be a volume mount.
```sh
BACKUP_DESTINATION=/backups
```
## Schedule
Back up pause. This specifies the delay between current backup ending to the time
the next one is started.
```sh
BACKUP_FREQUENCY=3600
```
If defined as an empty string, the container will exit once a single backup run is performed.