mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
dns: prompt for missing record parts in CLI
Fix the code which determines if a record part is required and thus should be prompted not to wrongfully consider all record parts to be optional. https://fedorahosted.org/freeipa/ticket/6203 Reviewed-By: Martin Basti <mbasti@redhat.com>
This commit is contained in:
committed by
Martin Basti
parent
afea961631
commit
dce95a1459
@@ -3471,6 +3471,21 @@ class dnsrecord(LDAPObject):
|
||||
)
|
||||
|
||||
|
||||
# Make DNS record types available as objects in the API.
|
||||
# This is used by the CLI to get otherwise unavailable attributes of record
|
||||
# parts.
|
||||
for param in _dns_records:
|
||||
register()(
|
||||
type(
|
||||
'dns{}record'.format(param.rrtype.lower()),
|
||||
(Object,),
|
||||
dict(
|
||||
takes_params=(param.parts or ()) + (param.extra or ()),
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
@register()
|
||||
class dnsrecord_split_parts(Command):
|
||||
NO_CLI = True
|
||||
|
||||
Reference in New Issue
Block a user