With the increase of computing scale, one computer cannot meet our needs. When we want to use a cluster of computers to provide services and achieve load balancing, failover, etc., Kubernetes can show its talents at this time.
In a word, what Kubernetes does is distribute your containers to a cluster to run, and perform fully automated management, including application deployment and upgrades
For more details on the use of Dockerfile and compose, it is recommended to refer to the official documentation. In addition, the Chinese tutorial of Docker is very good in the link of the reference material.
References