docker打包容器成镜像

2017/10/21 docker

docker打包镜像成容器

使用如下命令打包docker镜像image

Usage: docker commit [OPTIONS] CONTAINER [REPOSITORY[:TAG]]
Create a new image from a container's changes
  -a, --author=       Author (e.g., "John Hannibal Smith <hannibal@a-team.com>")
  -c, --change=[]     Apply Dockerfile instruction to the created image
  --help=false        Print usage
  -m, --message=      Commit message
  -p, --pause=true    Pause container during commit

使用方法

docker commit -m "centos6_nginx_php" -a "baby" b224a31432e3 centos6_nginx_php5.4.41:latest  

Search

    Table of Contents