我已经添加了一个域。
我想用certbot为新域启用https。
遵循此https://certbot.eff.org/lets-encrypt/ubuntubionic-apache
sudo certbot --apache
[sudo] password for qq:
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator apache, Installer apache
Which names would you like to activate HTTPS for?
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1: old.example.com
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Select the appropriate numbers separated by commas and/or spaces, or leave input
blank to select all options shown (Enter 'c' to cancel): 我只能看到我的旧域名。我有通过新域名的ssh。
如何添加新域名?
发布于 2019-12-11 21:12:34
我的猜测是您忘记在Apache配置中添加域。试着在/etc/apache2/sites-available上查看你的配置。
如果您的新域名已经配置,请检查/etc/apache2/sites-enabled中是否链接了配置文件,以查看是否已启用。如果是,请尝试重新加载apache2以确保加载了最新的配置
sudo systemctl reload apache2或者,如果配置不在那里,请尝试启用它们
sudo a2ensite my-new-config
sudo systemctl reload apache2如果新域仍然没有显示,您可以尝试手动生成证书,然后在配置中手动使用它:
sudo certbot certonly -d new-domain.com -d www.new-domain.comhttps://stackoverflow.com/questions/59285680
复制相似问题