mirror of
https://github.com/certbot/certbot.git
synced 2026-03-22 18:33:48 -04:00
Handle rmdir failure
This commit is contained in:
parent
9b5ff7bcd7
commit
4d9f487e89
1 changed files with 10 additions and 3 deletions
|
|
@ -144,6 +144,13 @@ to serve all files under specified web root ({0})."""
|
|||
|
||||
for root_path, achalls in six.iteritems(self.performed):
|
||||
if not achalls:
|
||||
logger.debug("All challenges cleaned up, removing %s",
|
||||
root_path)
|
||||
os.rmdir(root_path)
|
||||
try:
|
||||
os.rmdir(root_path)
|
||||
logger.debug("All challenges cleaned up, removing %s",
|
||||
root_path)
|
||||
except OSError as exc:
|
||||
if exc.errno == errno.ENOTEMPTY:
|
||||
logger.debug("Challenges cleaned up but %s not empty",
|
||||
root_path)
|
||||
else:
|
||||
raise
|
||||
|
|
|
|||
Loading…
Reference in a new issue