From 627ca74b51d68651a6cd042d83a0386713f15b39 Mon Sep 17 00:00:00 2001 From: Andrew Lazarev Date: Wed, 29 Oct 2014 17:01:15 -0700 Subject: [PATCH] [Sahara] Copy policy.json if it exists To enable policy check in Sahara we need gate tests passed. Tests will not pass until Sahara has default policy.json ( e.g. http://logs.openstack.org/09/131609/1/check/check-tempest-dsvm-full/536d5e7/console.html). New code will copy of policy.json if it exists. So, for now this code will do nothing. Once policy.json appears in etc/sahara, the code will start coping it to sahara conf dir. This will allow to merge auth support with gate tests passed. Related blueprint: auth-policy Change-Id: I98e108ff02aacb91570f97e457d67dd02779ae3d --- lib/sahara | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/sahara b/lib/sahara index 5c7c2534e2..7f59cc1f2e 100644 --- a/lib/sahara +++ b/lib/sahara @@ -98,6 +98,10 @@ function configure_sahara { fi sudo chown $STACK_USER $SAHARA_CONF_DIR + if [[ -f $SAHARA_DIR/etc/sahara/policy.json ]]; then + cp -p $SAHARA_DIR/etc/sahara/policy.json $SAHARA_CONF_DIR + fi + # Copy over sahara configuration file and configure common parameters. cp $SAHARA_DIR/etc/sahara/sahara.conf.sample $SAHARA_CONF_FILE