Docker Service to Backup a PostgreSQL Database

I have written a docker service to be used to periodically backup the data of a PostgreSQL Database. This container can be used to be part of a docker stack in a docker-compose.yml file.

version: '3.1'

services:
  ...
  backup:
    image: imixs/backup
    environment:
      SETUP_CRON: "0 3 * * *"
      BACKUP_POSTGRES_USER: "postgres"
      BACKUP_POSTGRES_PASSWORD: "xxxxxxxxxx"
      BACKUP_POSTGRES_HOST: "db"
      BACKUP_LOCAL_ROLLING: "5"
 ....

The service runs a cron job an uploads backup files automatically into a remote backup space via SFTP/SCP.

The Service is published on GitHub
and DockerHub
.

责编内容来自:Ralph's Open Source Blog (源链) | 更多关于

阅读提示:酷辣虫无法对本内容的真实性提供任何保证,请自行验证并承担相关的风险与后果!
本站遵循[CC BY-NC-SA 4.0]。如您有版权、意见投诉等问题,请通过eMail联系我们处理。
酷辣虫 » 后端存储 » Docker Service to Backup a PostgreSQL Database

喜欢 (0)or分享给?

专业 x 专注 x 聚合 x 分享 CC BY-NC-SA 4.0

使用声明 | 英豪名录