I had setup a new Apache server and needed an SSL certificate so i went with the tried and true, quick and easy LetsEncrypt/certbot route.
While testing if gzip was installed, i received errors running
apachectl configtest. Never had this happened before. It seemed to be caused by the LetsEncrypt install. I probably wouldn’t have noticed it for quite some time since the https:// version of the site i just put up on the new Apache server was working.
AH00526: Syntax error on line 27 of /etc/apache2/sites-enabled/domain-name-here.com-le-ssl.conf:
SSLCertificateFile: file '/etc/letsencrypt/live/domain-name-here.com/fullchain.pem' does not exist or is empty
I scoured the usual sites for server config issues like DigitalOcean and StackOverflow, but nothing suggested worked. I ended up finding some comment looking at it from a permissions issue. Smart thinking since that was a part of what i was running into as you can see from the screenshot below.
I ended up changing the permissions on the
/etc/letsencrypt/live directory and the
configtest command passed. No more error. Boom. Fixed!
sudo chmod 755 /etc/letsencrypt/live.