Nixos/ Docker - bind mounts & symlink suggestions

Hi there.

For those of you using docker on nixos, how are you dealing with bind mounts and symlinks?

In my case, I have a python tool (available as a pip package) that is not in nixpkgs, nor have I been able to figure out how to get it done. I’m giving up on that as I have wasted too much time. Do the person who wrote the tool provides a docker container. Generally, it works great.

Now, I have some config files for the tool that I was trying to create using home.file (home manager).

As expected, these files are now a symlink. Which docker falls down on with bind mounts.

Sure, I can manually put real files in place. But I was hoping for a more “nix” like solution.

Especially as I have similar use cases for work too.

Any ideas?

Thank you.