aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBryn M. Reeves <bmr@redhat.com>2013-08-13 14:54:20 +0100
committerBryn M. Reeves <bmr@redhat.com>2013-08-13 14:54:20 +0100
commitc1b7d7ffdd685f0894f3370a17bf631d6facbab1 (patch)
tree8b4bdf2b9d43913e201a6b07a4308b20fcfacb65
parent89ef36a72c612cc667d52935f687219981b74240 (diff)
downloadsos-c1b7d7ffdd685f0894f3370a17bf631d6facbab1.tar.gz
Improve readability of add_copy_specs() usage in ldap.py
Use multi-line style for add_copy_specs() invocations in the ldap plug-in per the recommendations in Issue #173. Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
-rw-r--r--sos/plugins/ldap.py13
1 files changed, 10 insertions, 3 deletions
diff --git a/sos/plugins/ldap.py b/sos/plugins/ldap.py
index b16b7b30..4d330767 100644
--- a/sos/plugins/ldap.py
+++ b/sos/plugins/ldap.py
@@ -1,4 +1,4 @@
-### This program is free software; you can redistribute it and/or modify
+## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
## the Free Software Foundation; either version 2 of the License, or
## (at your option) any later version.
@@ -49,7 +49,10 @@ class RedHatLdap(Ldap, RedHatPlugin):
def setup(self):
super(RedHatLdap, self).setup()
- self.add_copy_specs(["/etc/openldap", "/etc/nslcd.conf"])
+ self.add_copy_specs([
+ "/etc/openldap",
+ "/etc/nslcd.conf"
+ ])
def postproc(self):
self.do_file_sub("/etc/nslcd.conf", r"(\s*bindpw\s*)\S+", r"\1***")
@@ -66,7 +69,11 @@ class DebianLdap(Ldap, DebianPlugin, UbuntuPlugin):
ldap_search = "ldapsearch -Q -LLL -Y EXTERNAL -H ldapi:/// "
- self.add_copy_specs(["/etc/ldap/ldap.conf", "/etc/slapd.conf", "/etc/ldap/slapd.d"])
+ self.add_copy_specs([
+ "/etc/ldap/ldap.conf",
+ "/etc/slapd.conf",
+ "/etc/ldap/slapd.d"
+ ])
self.add_cmd_output("ldapsearch -x -b '' -s base 'objectclass=*'")
self.add_cmd_output(ldap_search + "-b cn=config '(!(objectClass=olcSchemaConfig))'",