docker 容器的修改及保存

1.进入容器: docker exec -it container_name/container_id /bin/bash
2.退出容器: exit
3.提交修改:
docker commit -a "author" -m "message" container_name/container_id image_name: tag_name
参数说明
-a: 参数可选,用于指定作者,可以写你的名字
-m: 参数可选,提交信息,可以说一下你做了哪些修改
container_id: 该参数为被修改的容器ID
image_name: 此为新镜像的名字,可自定义
tag_name: 此为新镜像的标签,可不写,不写时标签默认为latest
发表评论 / Comment

用心评论~


Warning: Cannot modify header information - headers already sent by (output started at /data/home/qxu1146270045/htdocs/content/templates/DYBLOG/footer.php:51) in /data/home/qxu1146270045/htdocs/include/lib/view.php on line 23