繁体   English   中英

如何为一个启用SSL的域激活2个端口80和4000?

[英]How to activate 2 ports 80 & 4000 for a single SSL enabled domain?

我是SSL加密的新手,需要帮助! (使用cert bot)。

我最近在一个在apache和linux上运行端口80的网站上激活了SSL。因此,当前网站看起来像:

http://example.com --> https://example.com (done)

但是,我有后端在端口4000上运行,并且还希望对其进行加密,以避免出现“混合内容”页面错误:

http://example.com:4000 --> https://example.com:4000 (Not done yet)

这正是我所需要的,没有任何解决方法会有所帮助。 请指导。

提前致谢! :-)

您可以创建一个新的子域subdomain.example.com并将其指向example.com:4000 ,然后从LetsEncrypt请求一个新的SSL证书,并在使用certbot请求证书时指定多个子域。

certbot certonly --webroot -w /var/www/example/ -d www.example.com -d example.com -w /var/www/other -d other.example.net -d another.other.example.net

拥有证书和密钥后,将其添加到您的Web服务器配置中

在此处查看官方certbot文档

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM