diff options
| author | Joshua Harlow <harlowja@yahoo-inc.com> | 2015-02-23 16:53:47 -0800 | 
|---|---|---|
| committer | Joshua Harlow <harlowja@yahoo-inc.com> | 2015-02-23 16:53:47 -0800 | 
| commit | 3165ab2a9b9d5f90f40f4458b58d3e5dba8dc53e (patch) | |
| tree | 58455a3d9d506ddd8aa5ba4481e4e9c098a995c4 | |
| parent | 14d75254351009087efb5baa5cef808c5ef43e17 (diff) | |
| parent | 09e81d572d8461d8546f66eacd005bf3c9ae0e39 (diff) | |
| download | vyos-cloud-init-3165ab2a9b9d5f90f40f4458b58d3e5dba8dc53e.tar.gz vyos-cloud-init-3165ab2a9b9d5f90f40f4458b58d3e5dba8dc53e.zip | |
Make parameter list for get_hostname method consistent
| -rw-r--r-- | ChangeLog | 1 | ||||
| -rw-r--r-- | cloudinit/sources/DataSourceDigitalOcean.py | 2 | ||||
| -rw-r--r-- | cloudinit/sources/DataSourceGCE.py | 2 | 
3 files changed, 3 insertions, 2 deletions
| @@ -65,6 +65,7 @@     (LP: #1336855)   - FreeBsd: support config drive datasource [Joseph bajin]   - cc_mounts: support creating a swap file + - DigitalOcean & GCE: fix get_hostname consistency  0.7.5:   - open 0.7.5   - Add a debug log message around import failures diff --git a/cloudinit/sources/DataSourceDigitalOcean.py b/cloudinit/sources/DataSourceDigitalOcean.py index b20ce2a1..76ddaa9d 100644 --- a/cloudinit/sources/DataSourceDigitalOcean.py +++ b/cloudinit/sources/DataSourceDigitalOcean.py @@ -85,7 +85,7 @@ class DataSourceDigitalOcean(sources.DataSource):      def get_instance_id(self):          return self.metadata['id'] -    def get_hostname(self, fqdn=False): +    def get_hostname(self, fqdn=False, resolve_ip=False):          return self.metadata['hostname']      def get_package_mirror_info(self): diff --git a/cloudinit/sources/DataSourceGCE.py b/cloudinit/sources/DataSourceGCE.py index 2cf8fdcd..6936c74e 100644 --- a/cloudinit/sources/DataSourceGCE.py +++ b/cloudinit/sources/DataSourceGCE.py @@ -126,7 +126,7 @@ class DataSourceGCE(sources.DataSource):      def get_public_ssh_keys(self):          return self.metadata['public-keys'] -    def get_hostname(self, fqdn=False, _resolve_ip=False): +    def get_hostname(self, fqdn=False, resolve_ip=False):          # GCE has long FDQN's and has asked for short hostnames          return self.metadata['local-hostname'].split('.')[0] | 
