Closed as not planned
Description
See #7.
For backup for Pi-hole at least, in the GUI you can go to Settings > Teleporter and click 'Backup'. To automate it through the console, you can run pihole -a -t
(can I integrate it with something like my geerlingguy.backup
role?).
If I run docker-compose exec pihole /bin/bash pihole -a -t
it exports a file inside the container. docker-compose cp
is not a supported command yet (see docker/compose#3593), so will have to figure out the best way of scripting this... maybe something like:
- Create a
/backup
directory inside the container (mkdir -p /backup
). - Run the
pihole -a -t
command inside the/backup
directory. - Cat the contents of
/backup/[latest-file-with-extension].tar.gz
and pipe them to file on host. - Delete contents of
/backup
directory (rm -rf /backup/*
).
It would be convenient for the pihole -a -t
command to have an option to output the archive to shell instead of into a file, that would save the whole file-based annoying process.