Detailed tutorial on installing Docker on Windows

Detailed tutorial on installing Docker on Windows

Since my local MySQL version is relatively low, I have been thinking about upgrading the MySQL version recently. In view of the popularity of Docker containers, I thought about installing a Docker environment locally, and then downloading the latest version of the MySQL image to complete the installation of MySQL 8.0. The computer is Windows 10 version.

1. Enable Hyper-V

Open Control Panel-->Programs-->Turn Windows features on or off, check Hyper-V, and click OK.



After clicking OK, you will be prompted to restart the system.

2. Install Docker

Download address: https://hub.docker.com/editions/community/docker-ce-desktop-windows. You must register an account before downloading. Direct download is very slow.



Another way to obtain it is to follow the official account "情系IT" and reply "docker" to obtain the installation exe file.

Three start docker

After obtaining the exe file, simply click Next to complete the installation. After the installation, you will be prompted to restart the computer. A docker icon will appear on the desktop, click to start it. Open the Windows command line mode and enter docker version or docker -v to view. If the following information is displayed, the installation is successful.


Four domestic mirror acceleration

Alibaba Cloud mirror acceleration address: https://cr.console.aliyun.com/cn-hangzhou/instances/mirrors

Get the exclusive accelerator address, as shown below:



Open Docker, right-click Settings-->Daemon-->Registry mirrors and copy the exclusive accelerator address just now to this place. This completes the domestic mirror acceleration.


5. Mobile image storage directory

Docker under Windows 10 has a visual operation interface and command line operation. After downloading docker-ce.exe, double-click it and it will automatically start and end. It is installed in the C drive directory by default, which means that many default parameters or configuration files are in the C drive directory. Considering that the C drive is the system drive, many image files may be pulled during the use of Docker, so we need to modify the default image file storage address of Docker.

Open Hyper-V Manager.

1. Right-click the Start menu -> Control Panel -> Administrative Tools -> Hyper-V Manager

Right-click and select Hyper-V Settings, and change the storage path shown in the figure below to the location you want to store.


Then add the following configuration in Settings-->Daemon-->Advanced:


Possible problems


The solution is:

cd "C:\Program Files\Docker\Docker"
DockerCli.exe -SwitchDaemon

In this way, we have completed the docker installation of windows10. In the next chapter, we will install and run the mysql8.0 image.

Summarize

The above is the tutorial on how to install Docker under Windows introduced by the editor. I hope it will be helpful to everyone. If you have any questions, please leave me a message and the editor will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website!
If you find this article helpful, please feel free to reprint it and please indicate the source. Thank you!

You may also be interested in:
  • Docker installation and deployment tutorial under CentOS7.6 system
  • Detailed steps to install Docker on CentOS7
  • Docker installation and running SRS process record

<<:  A brief analysis of using JDBC to operate MySQL requires adding Class.forName("com.mysql.jdbc.Driver")

>>:  A brief discussion on where the token generated by node using jwt should be stored

Recommend

mysql code to implement sequence function

MySQL implements sequence function 1. Create a se...

How to create a table by month in MySQL stored procedure

Without going into details, let's go straight...

MySQL 8.0.15 winx64 installation and configuration method graphic tutorial

This article shares the installation and configur...

JavaScript quickly implements calendar effects

This article example shares the specific code of ...

Encapsulation method of Vue breadcrumbs component

Vue encapsulates the breadcrumb component for you...

Two box models in web pages (W3C box model, IE box model)

There are two types of web page box models: 1: Sta...

Detailed explanation of common for loop in JavaScript statements

There are many loop statements in JavaScript, inc...

Common methods of Vue componentization: component value transfer and communication

Related knowledge points Passing values ​​from pa...

PostgreSQL materialized view process analysis

This article mainly introduces the process analys...

Detailed explanation of using javascript to handle common events

Table of contents 1. Form events 2. Mouse events ...

MySQL server 5.7.20 installation and configuration method graphic tutorial

This article records the installation and configu...