How to remove a volume in a Dockerfile

后端 未结 1 1458
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-01-27 05:13

I\'m experiencing the same problem as found here: mkdir .ssh in a Dockerfile, folder is not there?

I\'m wondering if there is a way for my dockerfile to remove a volume

1条回答
  •  执笔经年
    2021-01-27 05:33

    See also How to remove configure volumes in docker images

    Actually I did have a very similar use case in using an image from production that would be modified for testing. The only chance is to modify the metadata of the parent image. As I need to that regulary, I have created a little script for that, have a look at docker-copyedit if that can help you.

    0 讨论(0)
提交回复
热议问题