[Docker version] Unable to make extensions persistent
Hi!
Having an issue with persistency of the docker container. All is working well and I can install blueprint extensions. But as soon as I re-create the containers (clean/wipe and rebuild) all extensions are gone and I have to re-install them.
Reproducing the issue:
1. Build container
2. Install extension with blueprint -i xyz
3. Rebuild container and lose all extensions
Below is the relevant volume bindings section. I used the classic-docker-compose.yml for my stack.
volumes: - "./var/:/app/var/" - "./nginx/:/etc/nginx/http.d/" - "./logs/:/app/storage/logs" - "./extensions/:/blueprint_extensions"Notes: -using relative bindings with ./ as I don't have a /srv folder on my nas but rather keep all my docker data in one folder on my synology */volume1/docker/ * (e.g. /volume1/docker/pterodactyl/panel/extensions) -not binding the certs folder as I use my own reverse proxy -removed also the :/app binding as the panel container would be stuck in a boot loop (entrypoint not found), and chatgpt suggested this binding is the culprit and not necessary. after removing that binding all worked fine, but I'm aware that might also be the reason why the extensions disappear after a rebuild^^
5 Replies
This is the folder structure. I kept the /app folder since the unsuccesful attempt but unbinded it.

What does your compose file look like?
-# Remember to redact passwords
Solution
You're missing a volume. Add
under panel volumes, and add
at the bottom of your compose file (no indentation).
That solved it, thanks a lot 🙏
Also was sent down a rabbit hole learning a lot about named volumes vs. relative/absolute volume bindings. For anyone interested and running into the same issue:
If you mount an empty volume to /app inside the container via relative or absolte paths, it will essentially wipe the containers counterpart, i.e. the whole /app folder, when starting the container. So you have to use named volumes instead (at least for /app, I kept the relative bindings for the other folders) as these are managed by Docker. And even if they're empty at the beginning, they're going to be prepopulated when the container starts.