Answer the question
In order to leave comments, you need to log in
When starting the docker container, I forgot to set the volume, how to fix the assumption in running mode?
I started the container with the docker run command. But apart from the --net=host and --restart=always parameter, it did nothing. Now the files I need are accumulating in the container, and I'm scratching my head on how to configure the export of files from the container to the host machine The
question is twofold, I'm interested in two senses:
1) you need your solution, and it's better the one you use yourself, and it's personally verified by you ;
2) and what can be done in theory, because in addition to the network parameters, restart and mount, there are many parameters.
PS At the stage of launching a container, you do not always know what you need in a month or a year, and what to do?
How to deal with docker, are there any gurus on this subject? I look forward to your detailed response.
Answer the question
In order to leave comments, you need to log in
A container is not some kind of forever running entity that you need to work with.
Containers should be killed and created without affecting user data (for example, when updating software).
In your case, you copy the "files you need" to a folder on the host system using docker cp
, delete the container and start it with volume in this folder.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question