containerd 镜像拉取 ns 参数支持 #72
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
containerd 在拉取镜像的时候实现了一个新的参数 ns ,当使用 mirror 拉取时会自动附加上这个参数来表示该镜像的原命名空间
例如,给 docker.io 配置 mirror 的时候,containerd 会在请求中添加
?ns=docker.io能否利用这个参数至少在 containerd 里实现无需修改镜像名的镜像拉取
https://github.com/containerd/containerd/blob/main/docs/hosts.md#registry-host-namespace
支持了,加了个判断,不知是否可行,在
ns分支你自己编译测试一下https://github.com/sky22333/hubproxy/tree/ns
很好用
支持了吗?有啥问题吗?
我的k3s上已经在用了,目前没有出现任何问题,完全可以直接合并到主分支上去了
ok,感谢测试
用了一会,反馈一下,似乎目前?ns=docker.io时会400,建议ns=docker.io时视为不存在ns这个参数
试试最新版本,应该不会出现此问题了