Backing Up Docker Volumes
When You'd Use This
If none of these apply, stop here and use the in-app backup instead.
Docker Volumes
All Koios data lives in seven Docker volumes:
The four Critical volumes are enough to rebuild a working install. The other three carry uploads and configuration that are convenient to keep but recoverable from elsewhere — though losing koios_certs drops the web interface back to its built-in self-signed certificate, so you would need to install your certificate again.
Backup
Back up a volume by running a temporary Alpine container that mounts the volume and creates a tar archive in the current directory:
Run the same command for each volume you want to back up, swapping the volume name and archive filename. At minimum, back up the four Critical volumes (koios_data_postgres, koios_data_influxdb, koios_secrets, koios_media). Add koios_license to keep an activated license, and koios_certs to keep an installed web-interface certificate.
To leave the built stacks out of the koios_media archive, exclude the stacks/ directory:
The uploaded wheels are still archived, so you can rebuild each stack from Components > Stacks after restoring.
Restore
Stop Koios, then restore each archive back into its volume. This command reads the whole archive first, then deletes the volume's contents before extracting, so the restore is a clean replacement. A missing or damaged archive leaves the volume as it was:
Repeat for every volume you need to restore, then start Koios again.
If only koios_data_postgres was lost, Koios starts with a new, empty configuration database, and the saved copies of the old one are still on koios_media: the copy taken before each upgrade, and any archive from System > Backup & Restore. Stop Koios and restore one with step 3 of Downgrade to a Previous Version, using the image you run now.
What's Next
- Backup & Restore: the in-app backup that runs without stopping Koios and supports scheduled retention.
