[Maas-devel] juju's private-address, DNS, MAAS and postgresql
Andreas Hasenack
andreas at canonical.com
Fri Nov 8 19:42:19 UTC 2013
On Fri, Nov 8, 2013 at 3:58 PM, Gavin Panella
<gavin.panella at canonical.com>wrote:
> > postgresql/0:db-relation-changed % unit-get public-address
> > kmkxr.maaslocal
> >
> > postgresql/0:db-relation-changed % unit-get private-address
> > kmkxr.maaslocal
>
> I guess we could change MAAS to return an IP address, or the generated
> hostname, for private-address.
>
I tried AWS and LXC, postgresql works there just fine. No CNAMEs involved,
and no mangling of /etc/hosts like in the MAAS case.
I think it boils down to juju somehow ending up using the CNAME instead of
the A record or the IP for "private-address". The postgresql charm uses
that for access control, and using a CNAME for that doesn't work.
If the CNAME were not in /etc/hosts, it would work: "hostname -f" (which I
assume is what juju is calling, or its equivalent) would return the correct
dns record (and not the CNAME). And looks like MAAS explicitly wants the
hostname in /etc/hosts (via manage_etc_hosts):
./src/maasserver/compose_preseed.py:
def compose_cloud_init_preseed(token, base_url=''):
"""Compose the preseed value for a node in any state but
Commissioning."""
(...)
local_config_yaml = yaml.safe_dump({
"manage_etc_hosts": "localhost",
"apt_preserve_sources_list": True,
})
Oh, look at what I found:
More recent bug asking to remove manage_etc_hosts:
https://bugs.launchpad.net/ubuntu/+source/maas/+bug/1087183
Original bug that asked to introduce it:
https://bugs.launchpad.net/maas/+bug/972067
Tug of war! :)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/maas-devel/attachments/20131108/36787e7c/attachment.html>
More information about the Maas-devel
mailing list