diff options
author | Bryn M. Reeves <bmr@redhat.com> | 2012-11-29 21:21:47 +0000 |
---|---|---|
committer | Bryn M. Reeves <bmr@redhat.com> | 2012-11-29 21:21:47 +0000 |
commit | eac6de26675938556865d90bd834c96334c396bd (patch) | |
tree | 0ff16bb82b305b43f7d2940df9b88f14bce46ab3 | |
parent | 377be073191b06c7141ec1a67bddeb0a9243c8d5 (diff) | |
download | sos-eac6de26675938556865d90bd834c96334c396bd.tar.gz |
Add a checkenabled() to jboss module
The jboss module's postproc() method assumes the module is enabled
and throws exceptions if __jbosshome is unset. Add a checkenabled()
method to prevent the module running when this path cannot be found.
-rw-r--r-- | sos/plugins/jboss.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sos/plugins/jboss.py b/sos/plugins/jboss.py index cffaf043..de1a9765 100644 --- a/sos/plugins/jboss.py +++ b/sos/plugins/jboss.py @@ -641,6 +641,11 @@ Default=\'all default minimal production standard web\'.', '', False), self.addCopySpec(file) return + def checkenabled(self): + if not self.__getJbossHome(): + return False + return True + def setup(self): ## We need to know where JBoss is installed and if we can't find it we |