DaoCloud / crproxy

CRProxy (Container Registry Proxy) is a generic image proxy
MIT License
378 stars 98 forks source link

如何实现https访问 #16

Closed Dnyo666 closed 4 months ago

Dnyo666 commented 4 months ago

https://github.com/DaoCloud/crproxy/tree/master/examples/simple

这里面提到可以自行部署,但是需要80和443端口,也就是宝塔面板上安装了nginx无法正常部署docker

那么请问如何绑定域名进行https访问或者反代?

wzshiming commented 4 months ago

没用过宝塔面板, 基本上你把 acme 参数去掉

宝塔面板处理完 80 和 443 以及证书, 把请求 http 转发到 crproxy 8080 端口就好

Dnyo666 commented 4 months ago

好了,通过自行反代实现了域名https访问,不过在实际拉取时发现出现了:Error response from daemon: denied

wzshiming commented 4 months ago

你怎么用的

Dnyo666 commented 4 months ago

image image image image docker pull mirror.mtclub.top/nginx Using default tag: latest Error response from daemon: denied

wzshiming commented 4 months ago

docker pull mirror.mtclub.top/docker.io/nginx 这样拉呢

Dnyo666 commented 4 months ago

可以了,谢谢

wzshiming commented 4 months ago

--default-registry=docker.io加上这个才能省略 docker.io

Dnyo666 commented 4 months ago

这个是docker run参数吗,还是加载docker-compose.yaml里的

wzshiming commented 4 months ago

都行