juju/juju — pull request #1091 by wallyworld (2014-11-10 04:21:40+00:00)
Title: Merge pull request #1090 from wallyworld/unit-public-address-ec2

Unit public address ec2

Fixes: https://bugs.launchpad.net/bugs/1308374

The EC2 provider waits for the instance to advertise its DNS name, and when it does, it inserts this as a public address against the machine.
The unit's get public address method looks at the slice of machine addresses recorded and picks the first public one. If the DNS name is available before the first public IP address is recorded, this will be printed as the public address. So you sometimes get an IP address, sometimes a DNS name.

People want to get just IP addresses for unit's public/private addresses. So the EC2 provider recording of DNS name has been removed. This means that the juju status dns-name value will show an ip address, but that's what happens for HP Cloud and some other providers anyway, and we also want to get rid of dns-name.

Also a drive by fix for a go vet issue.