diff --git a/cloud-init.changes b/cloud-init.changes index 2f79618..c6da03f 100644 --- a/cloud-init.changes +++ b/cloud-init.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Sat Mar 29 21:40:00 UTC 2014 - rschweikert@suse.com + +- fix implementation of the openSUSE handler, properly read the configuration + from sysconfig + ------------------------------------------------------------------- Wed Mar 19 21:36:19 UTC 2014 - rschweikert@suse.com diff --git a/openSUSEHandler.diff b/openSUSEHandler.diff index 84d51f1..9966cec 100644 --- a/openSUSEHandler.diff +++ b/openSUSEHandler.diff @@ -1,7 +1,7 @@ diff -urN cloud-init-0.7.4/cloudinit/distros/opensuse.py cloud-init-0.7.4.os/cloudinit/distros/opensuse.py --- cloud-init-0.7.4/cloudinit/distros/opensuse.py 1969-12-31 19:00:00.000000000 -0500 +++ cloud-init-0.7.4.os/cloudinit/distros/opensuse.py 2013-06-15 06:26:15.312348359 -0400 -@@ -0,0 +1,86 @@ +@@ -0,0 +1,87 @@ +# vi: ts=4 expandtab +# +# Copyright (C) 2013 SUSE LLC @@ -25,6 +25,7 @@ diff -urN cloud-init-0.7.4/cloudinit/distros/opensuse.py cloud-init-0.7.4.os/clo +import os + +from cloudinit.distros import sles ++from cloudinit.distros import rhel_util + +from cloudinit.distros.parsers.resolv_conf import ResolvConf +from cloudinit.distros.parsers.sys_conf import SysConf @@ -81,7 +82,7 @@ diff -urN cloud-init-0.7.4/cloudinit/distros/opensuse.py cloud-init-0.7.4.os/clo + if len(out): + return out + else: -+ (_exists, contents) = self._read_conf(filename) ++ (_exists, contents) = rhel_util.read_sysconfig_file(filename) + if 'HOSTNAME' in contents: + return contents['HOSTNAME'] + else: