During the Let's Encrypt autorenewal process, add a htaccess file to work around protected roots
If you have a .htaccess in the root of your application, that adds a htpasswd based auth password for the entire site, the Let's Encrypt autorenewal process fails. The process create a subdirectory, .well-known/ and uses it for the renewal process, deleting it at the end of the process.
There are two easy ways to get around this that I can think of:
do not delete the .well-known directory at the end of the process. so that us customers can add in the .htaccess file in there if we want to, to leave it readable
-
as a part of the process of creating the short-lived .well-known directory, add a .htaccess file in that folder with the content:
Satisfy Any
Order Allow,Deny
Allow from all
And delete it all at the end of the process, as it does now. This will unlock that directory during the process automatically
