Pep8 fixes for opendj_backendprop_* (#24587)

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
pull/26477/head
Abhijeet Kasurde 7 years ago committed by John R Barker
parent 437ee6931a
commit 3004c913e6

@ -99,6 +99,7 @@ RETURN = '''
class BackendProp(object):
def __init__(self, module):
self._module = module
@ -118,7 +119,7 @@ class BackendProp(object):
else:
self._module.fail_json(msg="Error message: " + str(stderr))
def set_property(self, opendj_bindir, hostname, port, username, password_method, backend_name,name, value):
def set_property(self, opendj_bindir, hostname, port, username, password_method, backend_name, name, value):
my_command = [
opendj_bindir + '/dsconfig',
'set-backend-prop',
@ -159,7 +160,9 @@ def main():
value=dict(required=True),
state=dict(default="present"),
),
supports_check_mode=True
supports_check_mode=True,
mutually_exclusive=[['password', 'passwordfile']],
required_one_of=[['password', 'passwordfile']]
)
opendj_bindir = module.params['opendj_bindir']
@ -177,11 +180,6 @@ def main():
password_method = ['-w', password]
elif module.params["passwordfile"] is not None:
password_method = ['-j', passwordfile]
else:
module.fail_json(msg="No credentials are given. Use either 'password' or 'passwordfile'")
if module.params["passwordfile"] and module.params["password"]:
module.fail_json(msg="only one of 'password' or 'passwordfile' can be set")
opendj = BackendProp(module)
validate = opendj.get_property(opendj_bindir=opendj_bindir,
@ -212,7 +210,7 @@ def main():
module.exit_json(changed=False)
from ansible.module_utils.basic import *
from ansible.module_utils.basic import AnsibleModule
if __name__ == '__main__':
main()

@ -244,7 +244,6 @@ lib/ansible/modules/files/replace.py
lib/ansible/modules/files/synchronize.py
lib/ansible/modules/files/tempfile.py
lib/ansible/modules/files/xattr.py
lib/ansible/modules/identity/opendj/opendj_backendprop.py
lib/ansible/modules/messaging/rabbitmq_binding.py
lib/ansible/modules/messaging/rabbitmq_exchange.py
lib/ansible/modules/messaging/rabbitmq_parameter.py

Loading…
Cancel
Save