klren0312 / daliy_knowledge

知识积累,正确使用方式是watch
21 stars 4 forks source link

podman配置镜像地址 #870

Open klren0312 opened 8 hours ago

klren0312 commented 8 hours ago

1. 进入podman虚拟机

 podman machine ssh [optional-machine-name]

虚拟机名称可以使用podman machine list查看

2. 备份虚拟机镜像配置文件

sudo cp /etc/containers/registries.conf /etc/containers/registries.conf.bak

3. 编辑文件

sudo vi /etc/containers/registries.conf

文件内容

unqualified-search-registries = ["docker.io"]

[[registry]]
prefix = "docker.io"
location = "docker.1ms.run"
insecure = true

[[registry.mirror]]
location = "docker.1ms.run"
insecure = true
[[registry.mirror]]
location = "docker.rainbond.cc"
insecure = true
[[registry.mirror]]
location = "docker.udayun.com"
insecure = true
[[registry.mirror]]
location = "hub.geekery.cn"
insecure = true
[[registry.mirror]]
location = "ghcr.geekery.cn"
insecure = true