Issue
I was using wsl2 Ubuntu 20.04 with docker. I created a container in wsl, but when I exit from the container, the docker automatically deleted the container. Yet I didn't have this problem when I created a container from windows command line.
How to prevent docker from auto deleting the container I created in wsl command line?
Solution
It appears you may have created the container with docker run [...] --rm [...]
. This will cause the container to be removed when the container exits. To prevent auto-removal, be sure not to include --rm
when creating your container
Answered By - richyen Answer Checked By - Senaida (PHPFixing Volunteer)
0 Comments:
Post a Comment
Note: Only a member of this blog may post a comment.