Reputation: 127
How to remove file/folder from Docker container without starting this container? "Docker exec containerID rm filePath" can do it but it requires container in start state.
Upvotes: 5
Views: 12264
Reputation: 892
The only other way I can find is to create a Dockerfile and put a RUN rm /path/file/you/want/to/rm
into it...
Why want you to remove a file or a path without starting your container ?
Upvotes: 3