Disable cache for specific RUN commands

前端 未结 7 538
暗喜
暗喜 2020-11-30 05:16

I have a few RUN commands in my Dockerfile that I would like to run with -no-cache each time I build a Docker image.

I understand the

7条回答
  •  不知归路
    2020-11-30 05:44

    Not directly but you can divide your Dockerfile in several parts, build an image, then FROM thisimage at the beginning of the next Dockerfile, and build the image with or without caching

提交回复
热议问题