Sign inSign up

gordonchan/postgres-s3-backup

By gordonchan

•Updated almost 8 years ago

Daily Postgres DB backups, shipped to Amazon S3. Email notifications on every backup attempt.

Image
0

1.6K

gordonchan/postgres-s3-backup repository overview

⁠gordonchan/postgres-s3-backup

A Docker image designed to make daily backups of a Postgres database at 3pm UTC (3am NZST). Backups are stored locally on the container but are also uploaded to Amazon S3⁠. Email notifications are delivered on every backup attempt.

backup⁠ is used to manage backups and whenever⁠ is used to create the cron job. The main backup configuration file can be found here⁠.

This Docker image was created for my own selfish needs. It could be useful for others or be used as an example to create your own version.

⁠Environment variables

The following environment variables are expected to be set:

⁠Postgres
  • POSTGRES_DB
  • POSTGRES_USER
  • POSTGRES_PASSWORD
  • POSTGRES_HOST
  • POSTGRES_POST
⁠AWS
  • AWS_ACCESS_KEY_ID
  • AWS_SECRET_ACCESS_KEY
  • S3_REGION
  • S3_BUCKET
  • S3_PATH
⁠SMTP Email
  • MAIL_FROM
  • MAIL_TO
  • MAIL_ADDRESS
  • MAIL_PORT
  • MAIL_DOMAIN
  • MAIL_USER_NAME
  • MAIL_PASSWORD
  • MAIL_AUTHENTICATION
  • MAIL_ENCRYPTION
⁠License

Copyright (c) 2016 Gordon Chan. Released under the MIT License. It is free software, and may be redistributed under the terms specified in the LICENSE⁠ file.

Analytics

Tag summary

Content type

Image

Digest

Size

210.5 MB

Last updated

almost 8 years ago

docker pull gordonchan/postgres-s3-backup