我有一台安装了CentOS 7的VPS服务器,我想为IP地址启用SSL,并且我尝试为apache服务器安装了Letsencrypt的certbot,但它给出了一个错误,说明:
command: certbot --apache -d xxx.xx.xxx.xx
response: Requested name xxx.xx.xxx.xx is an IP address. The Let's Encrypt certificate authority will not issue certificates for a bare IP address.我在服务器上运行了Flask RestAPI,那么如何使用https://xxx.xx.xxx.xx来保护它呢?目前,我使用的是HTTP://xxx.xx.xxx.xx:5000/allusers。
发布于 2021-06-26 02:59:20
如响应所示,您不希望为服务器的IP地址请求SSL证书。您需要配置一个域名(例如,www.myflaskapp.com)以指向IP地址。这通常是在域名注册商处通过编辑域的DNS设置来完成的。一旦域名配置为指向服务器的IP地址,就可以将Apache配置为通过HTTP地址与IP中的域名为Flask应用程序提供服务。这也将允许您随后运行certbot来请求域名的SSL证书。
https://stackoverflow.com/questions/68132988
复制相似问题