From 2b726dacf1d2213c0a5ebc01f1db4f0caa8d06d5 Mon Sep 17 00:00:00 2001 From: Mustapha Lansana Date: Wed, 30 Jul 2014 20:38:33 -0400 Subject: openstack-base: support for openstackchef to hook into rootfs creation Openstack-base class is inheriting openstackchef class Since we want openstackchef post-rootfs function to be called after rootfs creation for all openstack images, openstack-base class need to inherit openstackchef class. In addition, we want the node names; compute/controller to be reconfigurable to other variables beside compute/controller in /etc/hosts file at run-time, and be consistent with node names used for compute/controller in all openstack installation. Signed-off-by: Mustapha Lansana --- meta-openstack/classes/openstack-base.bbclass | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'meta-openstack/classes') diff --git a/meta-openstack/classes/openstack-base.bbclass b/meta-openstack/classes/openstack-base.bbclass index 565470b..718aa1c 100644 --- a/meta-openstack/classes/openstack-base.bbclass +++ b/meta-openstack/classes/openstack-base.bbclass @@ -1,12 +1,12 @@ -inherit hosts +inherit hosts openstackchef ROOTFS_POSTPROCESS_COMMAND += "openstack_configure_hosts ; " openstack_configure_hosts() { bbnote "openstack: identifying hosts" - echo "${CONTROLLER_IP} controller" >> ${IMAGE_ROOTFS}/etc/hosts - echo "${COMPUTE_IP} compute" >> ${IMAGE_ROOTFS}/etc/hosts + echo "${CONTROLLER_IP} ${CONTROLLER_HOST}" >> ${IMAGE_ROOTFS}/etc/hosts + echo "${COMPUTE_IP} ${COMPUTE_HOST}" >> ${IMAGE_ROOTFS}/etc/hosts echo "${MY_HOST}" > ${IMAGE_ROOTFS}/etc/hostname } -- cgit v1.2.3-54-g00ecf