Add --range-type option that forces range type of the trusted domain
Adds --range-type option to ipa trust-add command. It takes two allowed values: 'ipa-ad-trust-posix' and 'ipa-ad-trust'. When --range-type option is not specified, the range type should be determined by ID range discovery. https://fedorahosted.org/freeipa/ticket/3650
This commit is contained in:
1 parent
fb166e8f5c
commit
e4437a3e7f
4 files changed
+43
-6
No files matched your search
@@ -458,12 +458,12 @@ class idrange_add(LDAPCreate):
|
||||
entry_attrs['objectclass'].append('ipatrustedaddomainrange')
|
||||
|
||||
# Default to ipa-ad-trust if no type set
|
||||
if 'iparangetype' not in entry_attrs:
|
||||
if not is_set('iparangetype'):
|
||||
entry_attrs['iparangetype'] = u'ipa-ad-trust'
|
||||
|
||||
if entry_attrs['iparangetype'] not in (u'ipa-ad-trust',
|
||||
u'ipa-ad-trust-posix'):
|
||||
raise errors.ValidationError('ID Range setup',
|
||||
raise errors.ValidationError(name='ID Range setup',
|
||||
error=_('IPA Range type must be one of ipa-ad-trust '
|
||||
'or ipa-ad-trust-posix when SID of the trusted '
|
||||
'domain is specified.'))
|
||||
|
||||
Reference in new issue
Block a user