From f17693e030d88d0d2a85d92d506506c34a0fb111 Mon Sep 17 00:00:00 2001 From: Bruce Ashfield Date: Mon, 10 Mar 2014 02:31:47 -0400 Subject: cloud-init: create skeleton package This creates a basic/skeleton cloud-init package that has the following properties: - working sysvinit scripts - Wind River distro definition - baseline cloud.cfg with no data source and "hands off" configuration Signed-off-by: Bruce Ashfield --- .../cloud-init/cloud-init_0.7.4.bb | 37 ++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 meta-openstack/recipes-extended/cloud-init/cloud-init_0.7.4.bb (limited to 'meta-openstack/recipes-extended/cloud-init/cloud-init_0.7.4.bb') 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 new file mode 100644 index 0000000..f639d4b --- /dev/null +++ b/meta-openstack/recipes-extended/cloud-init/cloud-init_0.7.4.bb @@ -0,0 +1,37 @@ +DESCRIPTION = "Init scripts for use on cloud images" +HOMEPAGE = "https://launchpad.net/cloud-init" +SECTION = "devel/python" +LICENSE = "GPLv3" +LIC_FILES_CHKSUM = "file://LICENSE;md5=d32239bcb673463ab874e80d47fae504" + +PR = "0" + +SRC_URI = "https://launchpad.net/cloud-init/trunk/${PV}/+download/${BPN}-${PV}.tar.gz \ + file://cloud-init-source-local-lsb-functions.patch \ + file://distros-add-windriver-skeleton-distro-file.patch \ + file://cloud.cfg" + +SRC_URI[md5sum] = "65053a7b2917ad1c26dc0a4d144b59c0" +SRC_URI[sha256sum] = "34152e0168c2ffc06284b4fe01ff43f856219228ddb995d5afe4f9a77420d779" + +S = "${WORKDIR}/${BPN}-${PV}" + +DISTUTILS_INSTALL_ARGS_append = " ${@base_contains('DISTRO_FEATURES', 'sysvinit', '--init-system=sysvinit_deb', '', d)}" +DISTUTILS_INSTALL_ARGS_append = " ${@base_contains('DISTRO_FEATURES', 'systemd', '--init-system=systemd', '', d)}" + +MANAGE_HOSTS ?= "False" +HOSTNAME ?= "" + +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 +} + +inherit setuptools update-rc.d + +FILES_${PN} += "${sysconfdir}/* \ + ${datadir}/*" + +INITSCRIPT_PACKAGES = "${PN}" +INITSCRIPT_NAME_${BPN} = "cloud-init" \ No newline at end of file -- cgit v1.2.3-54-g00ecf