mirror of
https://github.com/certbot/certbot.git
synced 2026-06-06 07:12:54 -04:00
Less generic exception for subprocess.check_call.
https://docs.python.org/2/library/subprocess.html#exceptions
This commit is contained in:
parent
cdde731aa4
commit
725d05e8ac
1 changed files with 1 additions and 1 deletions
|
|
@ -928,7 +928,7 @@ LogLevel warn \n\
|
|||
subprocess.check_call(["sudo", "a2enmod", mod_name], stdout=open("/dev/null", 'w'), stderr=open("/dev/null", 'w'))
|
||||
# Hopefully this waits for output
|
||||
subprocess.check_call(["sudo", "/etc/init.d/apache2", "restart"], stdout=open("/dev/null", 'w'), stderr=open("/dev/null", 'w'))
|
||||
except Exception as e:
|
||||
except (OSError, subprocess.CalledProcessError) as e:
|
||||
logger.error("Error enabling mod_" + mod_name)
|
||||
logger.error("Exception: %s" % str(e))
|
||||
sys.exit(1)
|
||||
|
|
|
|||
Loading…
Reference in a new issue