Please process your source codes with data, then pack them as a data container, see https://docs.docker.com/userguide/dockervolumes/
Step 1 Create app_src Image app_src
Put one Dockerfile in your git repository like
FROM BUSYBOX ADD . /container_src VOLUME /container_src
Then you can create the original image, for example
docker build -t app_src .
During the development period, you can always use your old solution -v /host_dev_src:/container_src .
Step 2 Transfer this docker image as an application image
You can transfer this app_src image to a test system similar to your application image, possibly through the docker registry
Step 3 Launch as a Data Container
In the test system, run the app container above it. (I use ubuntu for demonstration)
docker run -d -v /container_src --name code app_src docker run -it --volumes-from code ubuntu bash root@dfb2bb8456fe :/
Hope this helps
(give loans https://github.com/toffer/docker-data-only-container-demo , which I get detailed ideas)
source share