summaryrefslogtreecommitdiff
path: root/cloud-init.py
diff options
context:
space:
mode:
Diffstat (limited to 'cloud-init.py')
-rwxr-xr-xcloud-init.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/cloud-init.py b/cloud-init.py
index 32add699..bdfa9f01 100755
--- a/cloud-init.py
+++ b/cloud-init.py
@@ -146,7 +146,7 @@ def set_hostname(hostname, log):
log.error("failed to set_hostname")
def update_hostname(hostname, log):
- prev_file="%s/%s" % (cloudinit.datadir,"previous-hostname")
+ prev_file="%s/%s" % (cloudinit.get_cpath('datadir'),"previous-hostname")
etc_file = "/etc/hostname"
hostname_prev = None