charm-helpers
charm-helpers copied to clipboard
ApacheSSLContext.enable_modules produces unnecessary output
This context function (which is run everytime the class instance is used) generates the following output:
Considering dependency setenvif for ssl:
Module setenvif already enabled
Considering dependency mime for ssl:
Module mime already enabled
Considering dependency socache_shmcb for ssl:
Module socache_shmcb already enabled
Module ssl already enabled
Module proxy already enabled
Considering dependency proxy for proxy_http:
Module proxy already enabled
Module proxy_http already enabled
Module headers already enabled
The function responsible is:
class ApacheSSLContext(OSContextGenerator):
...
def enable_modules(self):
cmd = ['a2enmod', 'ssl', 'proxy', 'proxy_http', 'headers']
check_call(cmd)
If this were changed to:
def enable_modules(self):
cmd = ['a2enmod', 'ssl', 'proxy', 'proxy_http', 'headers', '1>/dev/null']
check_call(cmd, shell=True)
then the standard cruft would go, but we'd still get error messages. Thoughts?