Add support for heat resource templates
These are resources that are defined as a template and
can be customised by a deployer.
Change-Id: Ia739a36d627b7cfec26641b89513355e65cd1d1f
diff --git a/lib/heat b/lib/heat
index 5d6c6aa..8b6fd7f 100644
--- a/lib/heat
+++ b/lib/heat
@@ -33,6 +33,7 @@
HEAT_STANDALONE=`trueorfalse False $HEAT_STANDALONE`
HEAT_CONF_DIR=/etc/heat
HEAT_ENV_DIR=$HEAT_CONF_DIR/environment.d
+HEAT_TEMPLATES_DIR=$HEAT_CONF_DIR/templates
# Functions
# ---------
@@ -42,6 +43,7 @@
function cleanup_heat() {
sudo rm -rf $HEAT_AUTH_CACHE_DIR
sudo rm -rf $HEAT_ENV_DIR
+ sudo rm -rf $HEAT_TEMPLATES_DIR
}
# configure_heat() - Set config files, create data dirs, etc
@@ -163,6 +165,12 @@
# copy the default environment
cp $HEAT_DIR/etc/heat/environment.d/* $HEAT_ENV_DIR/
+ # heat template resources.
+ sudo mkdir -p $HEAT_TEMPLATES_DIR
+ sudo chown $STACK_USER $HEAT_TEMPLATES_DIR
+ # copy the default templates
+ cp $HEAT_DIR/etc/heat/templates/* $HEAT_TEMPLATES_DIR/
+
}
# init_heat() - Initialize database