-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consider bind mounting a directory instead of individual files #3142
Comments
Creating mount points instead of single files sounds like a great idea. It may end up being a breaking change, but collapsing to a single mount point, like this, would really simplify things:
|
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
bump |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
This issue was closed because it has been stalled for 5 days with no activity. |
Is your feature request related to a problem? Please describe.
Currently, the way to install Filebrowser with Docker is to create a bind mount for
/srv
,database.db
and optionally.filebrowser.json
:This comes with a couple issues, of which one is already documented:
The other issue I'm running against is when editing .filebrowser.json on the host, the changes are not reflected in the container.
After further investigation, the cause seems to be related to inodes mismatching between host and container.
You can see that after creating the container, the inodes are similar:
ls -i .config/filebrowser/.filebrowser.json 275438 .config/filebrowser/.filebrowser.json docker exec -it filebrowser ls -i .filebrowser.json 275438 .filebrowser.json
But after editing .filebrowser.json the inodes mismatch, causing the bind mount to become invalid:
ls -i .filebrowser.json 275455 .filebrowser.json docker exec -it filebrowser ls -i .filebrowser.json 275438 .filebrowser.json
And the contents of .filebrowser.json on the host and the container are not the same anymore.
Describe the solution you'd like
Instead of bind mounting specific files, bind mount a directory instead.
database.db and .filebrowser.json could live in their own directory, e.g.
/config
(to avoid mounting/
).Then in the docker-compose you'd only need to mount
/config
as so:This would eliminate both issues: needing to manually create database.db and invalidating the bind mount.
Describe alternatives you've considered
I haven't tested it, but a temporary workaround could be to create
/config
in the container manually, and hardlinking database.db and .filebrowser.json and then mounting it like that instead.Additional context
The text was updated successfully, but these errors were encountered: