I was able to update the name of the dnsresource using the cli. The docs for this api endpoint were wrong as we should have been using "name" instead of "fqdn":
root@maas-bionic:~# maas admin dnsresources read domain=com Success. Machine-readable output follows: [ { "address_ttl": null, "id": 3, "ip_addresses": [], "fqdn": "something.com", "resource_records": [], "resource_uri": "/MAAS/api/2.0/dnsresources/3/" }, { "address_ttl": null, "id": 4, "ip_addresses": [ { "created": "2019-05-29T21:52:51.432", "ip": "10.0.0.14", "alloc_type": 4, "subnet": { "name": "10.0.0.0/24", "vlan": { "vid": 0, "mtu": 1500, "dhcp_on": true, "external_dhcp": null, "relay_vlan": null, "id": 5002, "name": "untagged", "fabric": "fabric-1", "space": "undefined", "secondary_rack": null, "fabric_id": 1, "primary_rack": "6ef4cn", "resource_uri": "/MAAS/api/2.0/vlans/5002/" }, "cidr": "10.0.0.0/24", "rdns_mode": 2, "gateway_ip": "10.0.0.1", "dns_servers": [], "allow_dns": true, "allow_proxy": true, "active_discovery": false, "managed": true, "id": 2, "space": "undefined", "resource_uri": "/MAAS/api/2.0/subnets/2/" }, "alloc_type_name": "User reserved", "interface_set": [], "owner": { "is_superuser": true, "username": "admin", "email": "<email address hidden>", "is_local": true, "resource_uri": "/MAAS/api/2.0/users/admin/" }, "resource_uri": "/MAAS/api/2.0/ipaddresses/" } ], "fqdn": "yodawg.com", "resource_records": [], "resource_uri": "/MAAS/api/2.0/dnsresources/4/" } ] root@maas-bionic:~# maas admin dnsresource update 4 name=yodel Success. Machine-readable output follows: { "address_ttl": null, "fqdn": "yodel.com", "resource_records": [], "ip_addresses": [ { "created": "2019-05-29T21:52:51.432", "ip": "10.0.0.14", "alloc_type": 4, "subnet": { "name": "10.0.0.0/24", "vlan": { "vid": 0, "mtu": 1500, "dhcp_on": true, "external_dhcp": null, "relay_vlan": null, "name": "untagged", "id": 5002, "primary_rack": "6ef4cn", "fabric_id": 1, "fabric": "fabric-1", "secondary_rack": null, "space": "undefined", "resource_uri": "/MAAS/api/2.0/vlans/5002/" }, "cidr": "10.0.0.0/24", "rdns_mode": 2, "gateway_ip": "10.0.0.1", "dns_servers": [], "allow_dns": true, "allow_proxy": true, "active_discovery": false, "managed": true, "id": 2, "space": "undefined", "resource_uri": "/MAAS/api/2.0/subnets/2/" }, "interface_set": [], "alloc_type_name": "User reserved", "owner": { "is_superuser": true, "username": "admin", "email": "<email address hidden>", "is_local": true, "resource_uri": "/MAAS/api/2.0/users/admin/" }, "resource_uri": "/MAAS/api/2.0/ipaddresses/" } ], "id": 4, "resource_uri": "/MAAS/api/2.0/dnsresources/4/" }
I was able to update the name of the dnsresource using the cli. The docs for this api endpoint were wrong as we should have been using "name" instead of "fqdn":
root@maas-bionic:~# maas admin dnsresources read domain=com
"address_ ttl": null,
"ip_addresses" : [],
"resource_ records" : [],
"resource_ uri": "/MAAS/ api/2.0/ dnsresources/ 3/"
"address_ ttl": null,
"ip_addresses" : [
"created" : "2019-05- 29T21:52: 51.432" ,
"ip": "10.0.0.14",
"alloc_ type": 4,
"subnet" : {
" name": "10.0.0.0/24",
" vlan": {
"vid" : 0,
"mtu" : 1500,
"dhcp_ on": true,
"external_ dhcp": null,
"relay_ vlan": null,
"id" : 5002,
"name" : "untagged",
"fabric" : "fabric-1",
"space" : "undefined",
"secondary_ rack": null,
"fabric_ id": 1,
"primary_ rack": "6ef4cn",
"resource_ uri": "/MAAS/ api/2.0/ vlans/5002/ "
} ,
" cidr": "10.0.0.0/24",
" rdns_mode" : 2,
" gateway_ ip": "10.0.0.1",
" dns_servers" : [],
" allow_dns" : true,
" allow_proxy" : true,
" active_ discovery" : false,
" managed" : true,
" id": 2,
" space": "undefined",
" resource_ uri": "/MAAS/ api/2.0/ subnets/ 2/"
"alloc_ type_name" : "User reserved",
"interface_ set": [],
"owner" : {
" is_superuser" : true,
" username" : "admin",
" email": "<email address hidden>",
" is_local" : true,
" resource_ uri": "/MAAS/ api/2.0/ users/admin/ "
"resource_ uri": "/MAAS/ api/2.0/ ipaddresses/ "
"resource_ records" : [],
"resource_ uri": "/MAAS/ api/2.0/ dnsresources/ 4/" records" : [],
"created" : "2019-05- 29T21:52: 51.432" ,
"alloc_ type": 4,
"subnet" : {
"name" : "10.0.0.0/24",
"vlan" : {
" vid": 0,
" mtu": 1500,
" dhcp_on" : true,
" external_ dhcp": null,
" relay_vlan" : null,
" name": "untagged",
" id": 5002,
" primary_ rack": "6ef4cn",
" fabric_ id": 1,
" fabric" : "fabric-1",
" secondary_ rack": null,
" space": "undefined",
" resource_ uri": "/MAAS/ api/2.0/ vlans/5002/ "
"cidr" : "10.0.0.0/24",
"rdns_ mode": 2,
"gateway_ ip": "10.0.0.1",
"dns_ servers" : [],
"allow_ dns": true,
"allow_ proxy": true,
"active_ discovery" : false,
"managed" : true,
"id": 2,
"space" : "undefined",
"resource_ uri": "/MAAS/ api/2.0/ subnets/ 2/"
"interface _set": [],
"alloc_ type_name" : "User reserved",
"owner" : {
"is_superuser ": true,
"username" : "admin",
"email" : "<email address hidden>",
"is_local" : true,
"resource_ uri": "/MAAS/ api/2.0/ users/admin/ "
"resource_ uri": "/MAAS/ api/2.0/ ipaddresses/ " api/2.0/ dnsresources/ 4/"
Success.
Machine-readable output follows:
[
{
"id": 3,
"fqdn": "something.com",
},
{
"id": 4,
{
},
},
}
],
"fqdn": "yodawg.com",
}
]
root@maas-bionic:~# maas admin dnsresource update 4 name=yodel
Success.
Machine-readable output follows:
{
"address_ttl": null,
"fqdn": "yodel.com",
"resource_
"ip_addresses": [
{
"ip": "10.0.0.14",
},
},
},
}
],
"id": 4,
"resource_uri": "/MAAS/
}