1. The most complete Docker installation method for different systems

1.What is Docker?

◆ The container for the application

◆ The preferred containerization technology for development, testing, and operation and maintenance

◆ Lightweight

◆ Scalability

◆ Build once, share many times, run anywhere

2. Install Docker on Windows 10

◆ System requirements
Insert picture description here

◆ Download the installation package

https://download.docker.com/win/stable/Docker%20for%20Windows%20Installer.exe

◆ Just follow the installation wizard next

◆ Operation

Will not start automatically

Search for Docker in the start menu and open it
Insert picture description here
◆ For detailed configuration, please refer to this link:

https://docs.docker.com/docker-for-windows/#docker-settings-dialog

◆ Test whether the installation is successful

Run the following command in CMD. If the version number is displayed or "Hello from Docker!" is displayed, it means the installation is successful.
Insert picture description here
3. Install Docker in the old version of Windows

The following conditions must be met to install Docker on the old version of Windows
Insert picture description here

◆ Download the Docker ToolBox installation package

◆ Installation

Check version

For Windows 8 or 8.1, open Task Manager -> Performance -> Virtualization is enabled
Insert picture description here

  • For Windows 7 you can use this tool to detect whether virtualization is enabled

https://www.microsoft.com/en-us/download/details.aspx?id=592

◆ Double-click the exe installation package and follow the installation wizard next
Insert picture description here
◆ Test whether the installation is successful

Find the Docker QuickStart icon on the desktop and double-click to start Docker
Insert picture description here
◆ If prompted by User Account Control, click Yes

◆ A bash terminal will appear

◆ Run docker run hello-world, if "Hello from Docker." appears, it means the operation is successful
Insert picture description here
4. Install Docker
4.1 on Linux and install on Centos

◆ linux kernel version dependency

kernel version >= 3.8

You can use the following command to view

uname -a | awk ‘{split($3, arr, “-”); print arr[1]}’

◆ If you have already installed Docker, you need to remove the old version of Docker
Insert picture description here
◆ Add Docker repository yum source
Insert picture description here
◆ Start installing Docker Engine

Insert picture description here

◆ Start Docker
Insert picture description here

◆ Verify whether the installation is successful

Insert picture description here

◆ If "Hello from Docker." appears, it means the operation is successful

◆ If you run the docker command every time, without adding sudo in front, you can execute the following commands:

Insert picture description here

◆ If you think the above installation steps are troublesome, you can run the following script to install

Cannot be used in production system

Insert picture description here
4.2, install on Ubuntu

◆ linux kernel version dependency

kernel version >= 3.8

You can use the following command to view

uname -a | awk ‘{split($3, arr, “-”); print arr[1]}’

◆ The operating system depends on the following versions

Insert picture description here

◆ If you have already installed Docker, you need to remove the old version of Docker

Insert picture description here

◆ Use Docker repository to install

Insert picture description here
Insert picture description here

◆ Install Docker
Insert picture description here
◆ Start Docker

Insert picture description here

◆ Verify whether the installation is successful
Insert picture description here

◆ If "Hello from Docker." appears, it means the operation is successful

◆ If you run the docker command every time, without adding sudo in the front, you can execute the following commands:
Insert picture description here
5. Use a shell script to install Docker
and install it on Ubuntu and Centos

◆ install_docker_.sh
Insert picture description here
Insert picture description here
run script

◆ bash install_docker_.sh

6. Practice docker online

◆ katacoda website:

https://www.katacoda.com/

A small exercise every 10 minutes

◆ Play with Docker网站:

https://labs.play-with-docker.com/

Register a docker account and log in

Can be used for 4 hours at a time and will be emptied afterwards

Guess you like

Origin blog.csdn.net/weixin_45608577/article/details/109890232