'Mounting host volumes in development container

I have created a development container with some custom dependency compilation. After a few hours building it is time to run my first tests. My tests require loading files that are on the host disk (pretrained models and some data), in a separate folder. Running with tools like docker compose or docker command line I can share files of the host with the container by specifying volumes. The development container does the same with the code folder, but how can I specify additional volumes for development containers.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source