A warm Hello to all the readers!

While we are making changes in container, we need to make an image out it so that it can be copied to different system. Following is the process to make an image and later on create container out of that image.

List the running containers

$ sudo docker container ls

CONTAINER ID        IMAGE               COMMAND             CREATED             STATUS              PORTS               NAMES
462d8a700300        ubuntu:bionic       "bash"              28 hours ago        Up About an hour                        boring_wescoff

Next is to create the image. Image name is formatted as “space”/”name”:”tag”

$ sudo docker commit 462d8a700300 apex/webserver:1.0

List the new image

$ sudo docker images

REPOSITORY            TAG                 IMAGE ID            CREATED             SIZE
apex/webserver      1.0                 08715679d2b5        3 seconds ago       777MB

And we are done. Try it yourself.

Similar Posts

Error: GraphComment couldn't be load because your settings are invalid. Please visit your admin panel and go to the GraphComment section and enter a valid website URL/ID.