Skip to content

Instantly share code, notes, and snippets.

@yuryroot
yuryroot / db_backup.sh
Last active October 5, 2016 13:35
Bash script for backup Postgresql cluster
#!/usr/bin/env bash
# These ENV variables should be specified:
# * WORKING_DIR
# * PG_USER
# * SCP_USER
# * SCP_HOST
# * SCP_DIR
#
# Also optional variable MAIL_TO can be specified.