diff --git a/scripts/99_deploy.sh b/scripts/99_deploy.sh index 05f6af9..092570b 100755 --- a/scripts/99_deploy.sh +++ b/scripts/99_deploy.sh @@ -69,9 +69,16 @@ create_dir() { echo "error: unable to create the directory '${_directory}'" echo " command:" echo " runuser -l ${system_user} -c '${mkdir_command}'" - + echo "will try creating the directory as root, and changing owner" mkdir -p "${_directory}" + sudo chown -R ${system_user}:${system_user} "${_directory}" + if [ -d "$_directory" ] + then + echo "success!" + else + echo "failure! directory could not be created." + fi fi }