summaryrefslogtreecommitdiffstats
path: root/ipalib/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'ipalib/plugins')
-rw-r--r--ipalib/plugins/baseldap.py3
-rw-r--r--ipalib/plugins/host.py5
2 files changed, 7 insertions, 1 deletions
diff --git a/ipalib/plugins/baseldap.py b/ipalib/plugins/baseldap.py
index fbe4fcece..e7ccb7724 100644
--- a/ipalib/plugins/baseldap.py
+++ b/ipalib/plugins/baseldap.py
@@ -1002,6 +1002,7 @@ class LDAPAddMember(LDAPModMember):
"""
member_param_doc = 'comma-separated list of %s to add'
member_count_out = ('%i member added.', '%i members added.')
+ allow_same = False
has_output = (
output.Entry('result'),
@@ -1039,7 +1040,7 @@ class LDAPAddMember(LDAPModMember):
if not m_dn:
continue
try:
- ldap.add_entry_to_group(m_dn, dn, attr)
+ ldap.add_entry_to_group(m_dn, dn, attr, allow_same=self.allow_same)
except errors.PublicError, e:
ldap_obj = self.api.Object[ldap_obj_name]
failed[attr][ldap_obj_name].append((
diff --git a/ipalib/plugins/host.py b/ipalib/plugins/host.py
index 2abe70a12..f5dad59a9 100644
--- a/ipalib/plugins/host.py
+++ b/ipalib/plugins/host.py
@@ -133,6 +133,10 @@ host_output_params = (
),
Str('revocation_reason?',
label=_('Revocation reason'),
+ ),
+ Str('managedby?',
+ label=_('Failed managedby'),
+ flags=['no_create', 'no_update'],
)
)
@@ -726,6 +730,7 @@ class host_add_managedby(LDAPAddMember):
"""
member_attributes = ['managedby']
has_output_params = LDAPAddMember.has_output_params + host_output_params
+ allow_same = True
api.register(host_add_managedby)