aboutsummaryrefslogtreecommitdiffstats
path: root/meta-openstack/recipes-extended/cloud-init
diff options
context:
space:
mode:
authorKeith Holman <Keith.Holman@windriver.com>2014-06-11 09:53:34 -0400
committerBruce Ashfield <bruce.ashfield@windriver.com>2014-06-16 00:20:06 -0400
commit366d60a96c8f47d3a023579f6033938c62007475 (patch)
tree58c8359d55015ec13065e95d1ac2c87b2f006b6e /meta-openstack/recipes-extended/cloud-init
parenta062a1592df3552aef2932d8f856a975ab53cfa4 (diff)
downloadmeta-cloud-services-366d60a96c8f47d3a023579f6033938c62007475.tar.gz
meta-cloud-services-366d60a96c8f47d3a023579f6033938c62007475.tar.bz2
meta-cloud-services-366d60a96c8f47d3a023579f6033938c62007475.zip
cloud-init: install to correct target directory
The setup.py script that is included with the cloud-init code is setup to install files into the "/usr/lib" directory. On 64-bit machines the target directory should be "/usr/lib64". This generates a warning when using bitbake. This fix performs a search and replace on the setup.py file to set the correct output directory. This fix also adds a symbolic link to each script from the /etc/cloud directory to make the scripts available from a more obvious location. Signed-off-by: Keith Holman <Keith.Holman@windriver.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Diffstat (limited to 'meta-openstack/recipes-extended/cloud-init')
-rw-r--r--meta-openstack/recipes-extended/cloud-init/cloud-init_0.7.4.bb7
1 files changed, 7 insertions, 0 deletions
diff --git a/meta-openstack/recipes-extended/cloud-init/cloud-init_0.7.4.bb b/meta-openstack/recipes-extended/cloud-init/cloud-init_0.7.4.bb
index 57f689d..9e460a7 100644
--- a/meta-openstack/recipes-extended/cloud-init/cloud-init_0.7.4.bb
+++ b/meta-openstack/recipes-extended/cloud-init/cloud-init_0.7.4.bb
@@ -22,10 +22,17 @@ DISTUTILS_INSTALL_ARGS_append = " ${@base_contains('DISTRO_FEATURES', 'systemd',
MANAGE_HOSTS ?= "False"
HOSTNAME ?= ""
+do_install_prepend() {
+ sed -e 's:/usr/lib/${BPN}:${libdir}/${BPN}:' -i ${S}/setup.py
+}
+
do_install_append() {
sed -e "s:%MANAGE_HOSTS%:${MANAGE_HOSTS}:g" -i ${WORKDIR}/cloud.cfg
sed -e "s:%HOSTNAME%:${HOSTNAME}:g" -i ${WORKDIR}/cloud.cfg
install -m 0755 ${WORKDIR}/cloud.cfg ${D}${sysconfdir}/cloud/cloud.cfg
+
+ ln -s ${libdir}/${BPN}/uncloud-init ${D}${sysconfdir}/cloud/uncloud-init
+ ln -s ${libdir}/${BPN}/write-ssh-key-fingerprints ${D}${sysconfdir}/cloud/write-ssh-key-fingerprints
}
inherit setuptools update-rc.d