美文网首页
docker image version rollback

docker image version rollback

作者: 好小葱1 | 来源:发表于2018-07-31 11:49 被阅读13次
    If we want to make a rollback and remove the last layer (maybe the file should be called c.txt instead of b.txt) 
    we can do 
    so by tagging the layer 9977b78fbad7:
    $ docker tag 9977b test/b
    Let’s take a look at the new history:
    
    $ docker history test/b
    IMAGE               CREATED             CREATED BY                                      SIZE
    9977b78fbad7        3 hours ago         /bin/sh -c apt-get install -y apache2           54.17 MB
    e83b3bf07b42        3 hours ago         /bin/sh -c apt-get update                       20.67 MB
    9cd978db300e        3 months ago        /bin/sh -c #(nop) ADD precise.tar.xz in /       204.4 MB
    6170bb7b0ad1        3 months ago        /bin/sh -c #(nop) MAINTAINER Tianon Gravi <ad   0 B
    511136ea3c5a        10 months ago                                                       0 B
    Our last layer is gone and with the layer the text file b.txt!
    

    相关文章

      网友评论

          本文标题:docker image version rollback

          本文链接:https://www.haomeiwen.com/subject/gwyfvftx.html