Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.24/version: dial unix /var/run/docker.sock: connect: permission denied
$ docker run hello-world Unable to find image 'hello-world:latest' locally latest: Pulling from library/hello-world b8dfde127a29: Pull complete Digest: sha256:9f6ad537c5132bcce57f7a0a20e317228d382c3cd61edae14650eec68b2b345c Status: Downloaded newer image for hello-world:latest
Hello from Docker! This message shows that your installation appears to be working correctly.
To generate this message, Docker took the following steps: 1. The Docker client contacted the Docker daemon. 2. The Docker daemon pulled the"hello-world" image fromthe Docker Hub. (amd64) 3. The Docker daemon created anew container from that image which runs the executable that produces the output you are currently reading. 4. The Docker daemon streamed that output tothe Docker client, which sent it to your terminal.
To try something more ambitious, you can run an Ubuntu container with: $ docker run -it ubuntu bash
Share images, automate workflows, and more witha free Docker ID: https://hub.docker.com/
For more examples and ideas, visit: https://docs.docker.com/get-started/
查看当前镜像
1 2 3 4 5 6 7 8 9
$ docker images REPOSITORY TAGIMAGE ID CREATED SIZE hello-world latest d1165f221234 3 months ago 13.3kB Ps: REPOSITORY: 镜像的仓库源 TAG:镜像的标签 IMAGE ID:镜像的id CREATED:镜像的创建时间 SIZE:镜像的大小