Machine Addressability

Registered by Antonio Rosales

Juju should model the underlying cloud network in more detail

Currently juju just models addressing of machines as a "public hostname" and a "private hostname", that are known at machine creation and never change.
In real clouds, there may be only IP address not hostnames, no public addresses unless requested via api, and machine addressing may change across the lifetime of machines.

Blueprint information

Mark Ramm
Martin Packman
Needs approval
Series goal:
Not started
Milestone target:
Completed by
Katherine Cox-Buday

Related branches




Canonistack only assigns a 10. for a machine on startup, but can be accessed via a bastion host. To get a public address, a 'floating ip' must be subsequently added, which have limited availability. Users would like to be able to use juju without needing seperate nova api calls, or additional tools like sshuttle.

The initial version of HP cloud, and many private clouds, will only assign 10. addresses to machines on boot, and a floating ip must be added before even the bootstrap node can be accessed. When exposing a service, the user may expect a public address to be added automatically and advertised via status.

A new public cloud may be set up with an ipv6 address for each machine, but ipv4 addresses only provided at additional cost. The user expects to read the ipv6 address from status and connect and manage juju using those addresses.


Clouds use a variety of network setups, juju should handle some of the complexity and variation between deployments for end users and charm authors.


Charms that only use the old model may need some compatibility interfaces kept, and may need some backwards incompatible changes to take advantage of better address handling.


* New interface for fetching address information
* Dynamic address updates to running machines
* Assigning of public addresses at expose time
* Parsing and outputting assigned ipv6 addresses


* Full ipv6-only testing and support in juju
* Hostname management via juju
* Exposing advanced network configuration management through juju


Users will be able to:

* Tell whether a machine is publicly addressable
* Get the preferred address for connecting to a service
* Expose a service that lacks a public address with one juju command
* Write charms that are known to work without a public address for the machine
* Write charms that are robust when the public address of the machine changes



Work Items

Work items:
Move public/private address from unit to machine in state size 4: TODO
Change public/private addresses to list of Address types [needs serious thought - unit-get still needs to work] size 8: TODO
Add provider method for assigning/removing floating IP address size 1: TODO
Implement floating IPs for openstack size 4: TODO
Implement floating IPs for ec2 size 4: TODO
Figure out how to handle providers without floating IPs size 4: TODO
Save new addresses in state and propogate config change size 4: TODO
Update Firewaller to get public IP address if necessary when exposing size 2: TODO
Extend status output to show multiple addresses for machine [and unit, unless we get containers] size 2: TODO

This blueprint contains Public information 
Everyone can see this information.