diff options
-rw-r--r-- | ChangeLog | 2 | ||||
-rw-r--r-- | cloudinit/sources/DataSourceCloudStack.py | 3 |
2 files changed, 4 insertions, 1 deletions
@@ -105,6 +105,8 @@ - centos: Ensure that resolve conf object is written as a str (LP: #1479988) - chef: straighten out validation_cert and validation_key (LP: #1568940) - phone_home: allow usage of fqdn (LP: #1566824) [Ollie Armstrong] + - cloudstack: Only use DHCPv4 lease files as a datasource (LP: #1576273) + [Wido den Hollander] 0.7.6: - open 0.7.6 diff --git a/cloudinit/sources/DataSourceCloudStack.py b/cloudinit/sources/DataSourceCloudStack.py index 455a4652..4ba019df 100644 --- a/cloudinit/sources/DataSourceCloudStack.py +++ b/cloudinit/sources/DataSourceCloudStack.py @@ -206,7 +206,8 @@ def get_latest_lease(): latest_mtime = -1 latest_file = None for file_name in lease_files: - if file_name.endswith(".lease") or file_name.endswith(".leases"): + if file_name.startswith("dhclient.") and \ + (file_name.endswith(".lease") or file_name.endswith(".leases")): abs_path = os.path.join(lease_d, file_name) mtime = os.path.getmtime(abs_path) if mtime > latest_mtime: |