为Docker设置代理
修改 /etc/systemd/system/multi-user.target.wants/docker.service
在 [Service] 下面加上两行,记得将 socks5 代理替换为你自己的
Environment="HTTP_PROXY=socks5://127.0.0.1:1080" Environment="HTTPS_PROXY=socks5://127.0.0.1:1080"
然后重启 docker 引擎
systemctl daemon-reload systemctl restart docker
码字很辛苦,转载请注明来自.小东博客 .的《为Docker设置代理 》
06-11
746人浏览
点击这里取消回复。