In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
When running the container, if the image used does not exist locally, docker is automatically downloaded from the docker image repository. By default, it is downloaded from the Docker Hub public image source. We can search for images from the Docker Hub website at Docker Hub: https://hub.docker.com/, or we can use the docker search command to search for images. For example, we need an image of centos as our server. We can search centos with the docker search command to find the right image for us.
Search for images: docker search
Suggestions for choosing a mirror image: 1. Give priority to the large number of official 2.stars
[root@docker01 ~] # docker search centos
# Name: image name
# DESCRIPTION: description of the image
# STARS: the number of other stars. The greater the number, the higher the recognition.
# OFFICIAL: whether it is an official product
# AUTOMATED: whether to build for automation
Get image: docker pull (push) (image acceleration is required because of the wall, otherwise the connection timed out and cannot be downloaded)
Mirror Accelerator: Aliyun Accelerator, daocloud Accelerator, China University of Science and Technology Accelerator, Docker China official Image acceleration: https://registry.docker-cn.com
Docker pull centos:6.8 (no specified version, the latest version will be downloaded by default)
Docker pull daocloud.io/huangzhichong/alpine-cn:latest
Extension: query docker images for all versions of https://hub.docker.com/r/library/
Domestic is all mirror sites: https://www.douban.com/note/517555410/
The image names of private repositories are long (website address, user name, version name, etc.)
Docker mirroring other operations
1. View image: docker images (equivalent command: docker image ls)
REPOSITORY: image name
TAG: tags (customizable)
IMAGE ID: mirror ID (unique)
CREATED: creation time
SIZE: mirror siz
two。 Delete image docker rmi equivalent command (docker image rm) example: docker image rm centos:latest
# docker rmi centos:6, you need to tag the deleted container, otherwise (docker rmi centos) delete the latest version by default
3. Export image docker save equivalent command (docker image save) example: docker image save centos > docker-centos7.4.tar.gz
4. Import image docker load equivalent command (docker image load) example: docker image load-I docker-centos7.4.tar.gz
[root@docker01] # docker image load-I docker_centos6.8.tar.gz
-I: specify the imported image
5.docker other commands. You can view other docker commands through docker image.
[root@docker01 ~] # docker image
# build: build an image, which can be created manually
# history: view the history of the build image
# import: import image (deprecated)
# inspect: view image details and attributes
# load: import images
# ls: view the list of images
# prune: delete image (deprecated)
# pull: download image
# push: upload image
# rm: delete an image
# save: export an image
# tag: alias the image
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.