From 1bb758758bda040c94747dce5b22fc6692aa00d0 Mon Sep 17 00:00:00 2001 From: David Ripton Date: Fri, 1 Mar 2013 11:48:27 -0500 Subject: [PATCH] chown -R to ensure that stack user owns data_dir The fix for bug #1129748 tightens some permissions on image directories. This breaks the devstack gate jobs, which were relying on wide-open permissions. chowning recursively should ensure that all the directories are owned by the stack user, so the gate tests work with tighter permissions. Change-Id: I09be54bff6d8f9c3f7f599d6e5ada6431beb7c31 --- stack.sh | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/stack.sh b/stack.sh index 7dc046994e..86b835a0be 100755 --- a/stack.sh +++ b/stack.sh @@ -197,9 +197,7 @@ fi # Create the destination directory and ensure it is writable by the user sudo mkdir -p $DEST -if [ ! -w $DEST ]; then - sudo chown $STACK_USER $DEST -fi +sudo chown -R $STACK_USER $DEST # Set ``OFFLINE`` to ``True`` to configure ``stack.sh`` to run cleanly without # Internet access. ``stack.sh`` must have been previously run with Internet @@ -214,7 +212,7 @@ ERROR_ON_CLONE=`trueorfalse False $ERROR_ON_CLONE` # Destination path for service data DATA_DIR=${DATA_DIR:-${DEST}/data} sudo mkdir -p $DATA_DIR -sudo chown $STACK_USER $DATA_DIR +sudo chown -R $STACK_USER $DATA_DIR # Common Configuration