I ran this command: sudo certbot --apache
It produced this output:
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator apache, Installer apache
Please choose an account
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1: ip-171-30-18-55.us-east-2.compute.internal@2018-07-31T19:29:47Z (ee5c)
2: ip-171-30-7-155.us-east-2.compute.internal@2018-04-20T05:20:30Z (7de9)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Select the appropriate number [1-2] then [enter] (press 'c' to cancel): c
An unexpected error occurred:
AttributeError: 'NoneType' object has no attribute 'id'
Please see the logfiles in /var/log/letsencrypt for more details.
My web server is (include version): Apache 2.4.34
The operating system my web server runs on is (include version): Amazon Linux 2 (4.14.77-81.59.amzn2.x86_64 #1 SMP Mon Nov 12 21:32:48 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux)
My hosting provider, if applicable, is: AWS
I can login to a root shell on my machine (yes or no, or I don’t know): yes
Instead of picking up my domain name from the server config. file, Certbot seems to be identifying the internal IP of my AWS instance. Have never seen this before. Why is this happening and how do I fix it? I’m just going around and around in circles at this point.
Here’s what’s in my Apache config. file, httpd.conf:
<VirtualHost *:80>
Protocols h2 h2c http/1.1
DocumentRoot "/var/www/html"
ServerName mydomain.com
RewriteEngine on
RewriteCond %{SERVER_NAME} =mydomain.com
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
</VirtualHost>
#SSL
<VirtualHost *:443>
Protocols h2 h2c http/1.1
DocumentRoot "/var/www/html"
ServerName mydomain.com
</VirtualHost>