In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-21 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
Docker uses tips
1. Clean all stopped docker containers
Sometimes we have many containers that have been stopped or forced to exit unusable containers due to errors, so we need to delete them. But it is very troublesome for us to delete rm one by one. We have to rm as many containers as we have. We can find out the id of all containers according to docker ps-qa, and delete them all at once. Do not worry about deleting the running containers. The running container rm cannot be deleted, so we delete all stopped containers at once
# only applicable to docker rm $(docker ps-qa) in Linux environment
2. View the environment variables in the image
When we make an image or get an image, if we want to know its environment variables, the first thing we want to know is to create a container and see it. In fact, we don't have to, we can check it directly through env.
Docker run nginx env
3. The difference between Windows and Linux
The main reason for the difference between these two environments is the support of docker. We all know that docker was first released on Linux, relying on the Linux kernel, but not on Windows, so how do we use it now? virtual machines, if the versions below win10 are basically installed with VirtualBox,win10, many of them will choose the desktop version, and the Hyper-V used is also a kind of virtual machine. Only with a virtual machine can docker be used on windows. We should know the two differences by now.
On Linux, docker is directly on the Linux system, but unlike on windows, on the windows system is the virtual machine, and on the virtual machine is the docker.
Linux system
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.