问题描述
Docker 按照 @L_404_0@
安装为什么我可以从 dockerhub 运行原始拉取的图像,但如果我在本地构建一个版本,它就不会运行并且失败并出现主题中的错误。但是 sudo 图像有效。我缺少什么权限
[user@localhost:~/image]$ docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
fedora 33 b3048463dcef 5 weeks ago 175MB
[user@localhost:~/image]$ docker run -it fedora:33
[root@c5a6a048c295 /]# echo "worked"
worked
[root@c5a6a048c295 /]# exit
构建镜像
[user@localhost:~/image]$ echo "FROM fedora:33" | docker build -t my_image:v1 -
Sending build context to Docker daemon 2.048kB
Step 1/1 : FROM fedora@sha256:aa889c59fc048b597dcfab40898ee3fcaad9ed61caf12bcfef44493ee670e9df
---> b3048463dcef
Successfully built b3048463dcef
Successfully tagged my_image:v1
Tagging fedora@sha256:aa889c59fc048b597dcfab40898ee3fcaad9ed61caf12bcfef44493ee670e9df as fedora:33
[user@localhost:~/image]$ docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
my_image v1 b3048463dcef 5 weeks ago 175MB
fedora 33 b3048463dcef 5 weeks ago 175MB
[user@localhost:~/image]$ docker run -it my_image:v1
docker: you are not authorized to perform this operation: server returned 401.
See 'docker run --help'.
[user@localhost:~/image]$ sudo docker run -it my_image:v1
[sudo] password for user:
[root@013cf0ada215 /]# echo "only works with sudo"
only works with sudo
[root@013cf0ada215 /]# exit
一些版本信息
- Fedora 32
- Docker 版本 20.10.1,构建 831ebea
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)