centos7 installs docker and configures php running environment

Installation of docker

First, let's look at what docker is.

Docker is a virtualization technology based on the Linux kernel, which encapsulates and isolates processes. Because the isolated processes are independent of the host and other isolated processes, they can also be called containers. Many people think of docker as a virtual machine, but it is not, because it does not require additional overhead such as hardware virtualization and running a complete operating system. The docker also appears to solve the problem that no modification is needed in various complex environments and to ensure the normal and stable operation of the program, that is, the environment is consistent. The problem of sex, of course, is that kubernets, referred to as k8s, automates the management and arrangement of docker containers. The next article will introduce k8s.

7. Restart services

When it appears as shown in the figure, it proves that the installation was successful.

2. Configuring php running environment with docker

First of all, to create a private network, you can configure the environment without creating it, but to leak the ports out of the network and connect the containers with the link parameter, which is not safe. To create a private network, you only need to expose 80 ports, which is more secure.

I am also a novice to learn docker. The first step is to configure the environment. When I succeed in writing notes, the middle process can be omitted, such as using docker file, which is more convenient. When I learn k8s later, I will also record notes. I also hope that I can learn and make progress together with others.