version: '2' services: mongo-backup: image: mongo:3.2 volumes: - /local/backup/mongo:/backup command: 'mongodump --out /backup --host mongo'