LXC container and DNS names

Dimiter Naydenov dimiter.naydenov at canonical.com
Thu Oct 29 12:28:37 UTC 2015


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 29.10.2015 03:03, Pshem Kowalczyk wrote:
> Hi,
> 
> 
> I'm running a stable version of juju (1.24.7-trusty-amd64) and
> maas (1.8.2+bzr4041-0ubuntu1 (trusty1)). I use maas to manage DHCP
> and DNS on the 'bootstrap' network.
> 
Yes, in fact registering containers in MAAS (along with their MACs,
hostname, and parent instance) is what I'm working on currently. This
will allow MAAS to release the resources allocated to containers (so
far just IP addresses - static or DHCP-provided leases) when Juju
destroys a container, its parent instance, or the whole environment
(gracefully, i.e. without --force, or with --force, bypassing the
usual shutdown Juju performs and relying on MAAS to do it instead).

This will be the default behaviour starting from 1.24.8, and also will
apply the upcoming 1.25.0 release, as well as all future releases.

In order to be able to do that, for MAAS environments, Juju will
require at least MAAS 1.8+.

Containers will be registered as devices, and will have hostnames like
"juju-machine-1-lxc-2.maas" (assuming regular instances get hostnames
like "distinct-town.maas").

See bug https://bugs.launchpad.net/juju-core/+bug/1483879 for updates
on when this feature will be available for early testing, or
alternatively wait for the 1.24.8/1.25.0 releases.

Regards,
Dimiter

> 
> I would like to know if it's possible to get juju to register the
> DNS names for the containers it spins up. For example at this stage
> I get:
> 
> 
> 
> maascontroller:~$ juju status mysql
>  environment: maas machines: "0": agent-state: started 
> agent-version: 1.24.7 dns-name: controller.maas instance-id: 
> /MAAS/api/1.0/nodes/node-f2b1adb6-7603-11e5-a073-0050569a302e/ 
> series: trusty containers: 0/lxc/2: agent-state: started 
> agent-version: 1.24.7 dns-name: 10.0.0.148 instance-id:
> juju-machine-0-lxc-2 series: trusty hardware: arch=amd64 hardware:
> arch=amd64 cpu-cores=4 mem=65536M tags=4cpu 
> state-server-member-status: has-vote services: mysql: charm:
> cs:trusty/mysql-29 exposed: false service-status: current: unknown 
> since: 29 Oct 2015 13:24:18+13:00 relations: cluster: - mysql 
> shared-db: - glance - keystone - neutron-api - neutron-gateway -
> nova-cloud-controller - nova-compute units: mysql/0: 
> workload-status: current: unknown since: 29 Oct 2015
> 13:24:18+13:00 agent-status: current: idle since: 29 Oct 2015
> 13:34:53+13:00 version: 1.24.7 agent-state: started agent-version:
> 1.24.7 machine: 0/lxc/2 public-address: 10.0.0.148 networks: 
> maas-eth1: provider-id: maas-eth1 cidr: 10.0.0.0/24
> <http://10.0.0.0/24>
> 
> I would like juju to either create something like 
> juju-machine-0-lxc-2.maas (and preferably  mysql-0.maas). Is this
> possible?
> 
> 
> kind regards
> 
> Pshem
> 
> 
> 


- -- 
Dimiter Naydenov <dimiter.naydenov at canonical.com>
Juju Core Sapphire team <http://juju.ubuntu.com>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (GNU/Linux)

iQEcBAEBAgAGBQJWMhD1AAoJENzxV2TbLzHw4tgIAJKunUYnFq3GGQ3i5HbYT/mz
AYD1RHpdL6vbph3egFJU7JJG1kIAapMz7ediOcU7XfGKlbIS4hjag3K042MQQyK/
TkFZOIzIVAhGIvvrGO5BpkSLQp6hOTjKKWPGppDsU9O7jUZo3rbHneVww3kNbTSl
KDsLQHXZY1d1UCqX3OLsGQ/zUsgurcVQMjWVma+JygJkkNLJCKGkBdkQvqNJ/5jO
0T8gHJFpB3nrQfjQEt4Z2JJeX5OJLl0Zsil8vMxkPnVXjcNZQ7buPjsMght7eSOh
OcnbNM8WOo2ANTdtw/FnjN0RNgzspTGRN1FLce+5LypvzOEjZbm4qC5DbsgJvRM=
=b2W/
-----END PGP SIGNATURE-----



More information about the Juju mailing list