[openstack-dev] Question on hostname generation?

Sean M. Collins sean at coreitpro.com
Fri Aug 17 20:11:36 UTC 2012


On Mon, Aug 13, 2012 at 10:03:08AM -0700, Joshua Harlow wrote:
> I have a need/want… to make the hostname based off the IP (or one of the IPs if many) so it almost needs to hook-in to those places (and/or plugin extension like) to change that, might be something that others want also.

I have a client that has a similar requirement - we are carrying around
a patch against the create API of Openstack and also the NetworkManager
class - that only sends the instance UUID to our custom instance DNS
manager, instead of sending two records to the DNS manager - one for the 
display name and one for the UUID.

Take a look at the DNS manager class that Wikimedia contributed - that's
a pattern we followed.

Some links:

* https://github.com/openstack/nova/blob/master/nova/api/openstack/compute/servers.py#L625
* https://github.com/openstack/nova/blob/master/nova/network/dns_driver.py 
* https://github.com/openstack/nova/blob/master/nova/network/minidns.py
* https://github.com/openstack/nova/blob/master/nova/network/manager.py#L1266

-- 

Sean M. Collins
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 834 bytes
Desc: not available
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20120817/738a5f6a/attachment.pgp>


More information about the OpenStack-dev mailing list