Docker installation and ease of use

Source: Internet
Author: User
Tags docker hub

1. Installation of Docker

( "Installing Docker" here is actually installing Docker Engine)

$ sudo apt-get intasll Docker.io

  • Note:apt-get is a management tool for Ubuntu installation software
2. Verify that the Docker engine is installed successfully

# Check that you have a working install

$ sudo docker info

3. Download an image (Download a pre-built image)

# Download an Ubuntu image

$ sudo docker pull Ubuntu

  • Ubuntu is the name of the image, and you can search for the desired image in the Docker hub
4. Running an interactive shell

$ sudo docker run-it ubuntu/bin/bash

  • -I flag starts an interactive container.
  • -T flag creates a pseudo-tty that attaches and stdinstdout

5. Save a volume container as an image
    • If the changes to Docker are not software installed with Jupyter, but only some packages are installed, then saving the new image requires only
sudo docker commit Containerid newimagename
  • Containerid is the ID of the container to be saved
  • Newimagename is the name of the new image, such as the name Ting/caffe:version1, where Version1 is the flag of the new container, which can be used to identify the version information of the new image
6. Enter the running container
exec-it c18652dcc369 Bash
Here's

Docker installation and ease of use

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.