summaryrefslogtreecommitdiffstats
path: root/meta-openstack/recipes-support/deploychef/files
diff options
context:
space:
mode:
authorMustapha Lansana <Mustapha.Lansana@windriver.com>2014-05-27 22:02:55 -0400
committerBruce Ashfield <bruce.ashfield@windriver.com>2014-09-26 09:09:21 -0400
commit98e1afbc185a7f87427860f4273a7285e5b6407e (patch)
tree13558f56af0e27bcebd9202ed68e3c89efb317fa /meta-openstack/recipes-support/deploychef/files
parentea4560f65862a7c94d15cfe6006f8059ab62ea74 (diff)
downloadmeta-cloud-services-98e1afbc185a7f87427860f4273a7285e5b6407e.tar.gz
deploychef: makes chef-solo templates from openstack conf files
The current openstack build bakes a number of variables into openstack services' configuration files at build-time. This makes it impossible to deploy an openstack image built for one run-time environment into a different run-time environment. The deploychef package uses chef-solo to enable the re-use of an openstack image in different run-time environments. The attached patch set is deploychef package recipe and init script files. The script deploychef.init gives us the ability to make a copy of the postinstall script before they are tainted. This enables us to create chef-solo templates out of the untainted postinstall scripts. The template files are then used to recreate the postinstall script whenever the stack needs to be reconfigured at run-time. Signed-off-by: Mustapha Lansana <Mustapha.Lansana@windriver.com>
Diffstat (limited to 'meta-openstack/recipes-support/deploychef/files')
-rw-r--r--meta-openstack/recipes-support/deploychef/files/deploychef.inc16
-rw-r--r--meta-openstack/recipes-support/deploychef/files/deploychef.init11
2 files changed, 27 insertions, 0 deletions
diff --git a/meta-openstack/recipes-support/deploychef/files/deploychef.inc b/meta-openstack/recipes-support/deploychef/files/deploychef.inc
new file mode 100644
index 0000000..65ea2ca
--- /dev/null
+++ b/meta-openstack/recipes-support/deploychef/files/deploychef.inc
@@ -0,0 +1,16 @@
1#These variables are not defined in the services
2#We define them here with the option for them to
3#be overwritten in the future
4#Nova package name, see nova recipe
5SERVICE_USER ?= "nova"
6#Swift test.conf
7ADMIN_USER ?= "admin"
8#Neutron neutron.conf
9DEMO_USER ?= "demo"
10DEMO_PASSWORD ?= "password"
11#Use in ceilometer, openrc (nova& keystone)
12OS_USERNAME ?= "admin"
13OS_TENANT_NAME ?= "admin"
14OS_PASSWORD ?= "password"
15POSTINSTS_DIR ?= "rpm-postinsts"
16
diff --git a/meta-openstack/recipes-support/deploychef/files/deploychef.init b/meta-openstack/recipes-support/deploychef/files/deploychef.init
new file mode 100644
index 0000000..b456e35
--- /dev/null
+++ b/meta-openstack/recipes-support/deploychef/files/deploychef.init
@@ -0,0 +1,11 @@
1#!/bin/bash
2#After this script runs, chefsolo postinsts templates
3#script will all be in chefsolo default templates directory
4i=%DEPLOYCHEF_ROOT_DIR%/generate-templates
5if [ -f $i ] && $i; then
6 echo "Chefsolo templates made successfully"
7 rm -f /etc/rcS.d/S96deploychef
8 rm -f $i
9else
10 echo "ERROR: $i failed."
11fi