File tree Expand file tree Collapse file tree 1 file changed +3
-13
lines changed
OracleIdentityGovernance/samples/scripts Expand file tree Collapse file tree 1 file changed +3
-13
lines changed Original file line number Diff line number Diff line change @@ -91,12 +91,7 @@ createDir(){
9191
9292 if [ -d " $absoluteVolumePath " /data ]
9393 then
94- if [ " $( podman --version 2> /dev/null) " ]
95- then
96- chmod -R 777 " $absoluteVolumePath " /data > /dev/null 2>&1
97- else
9894 chmod -R 775 " $absoluteVolumePath " /data > /dev/null 2>&1
99- fi
10095 fi
10196
10297
@@ -314,9 +309,9 @@ runAgent(){
314309 then
315310 echo " INFO: Starting new container."
316311 if [ -f " $CONFDIR " /config.properties ]; then
317- podman run -d --env-file " $CONFDIR " /config.properties -v " $PV " :/app --group-add " $groupId " --name " $AI " " $imageName "
312+ podman run -d --user root -- env-file " $CONFDIR " /config.properties -v " $PV " :/app --group-add " $groupId " --name " $AI " " $imageName "
318313 else
319- podman run -d -v " $PV " :/app --group-add " $groupId " --name " $AI " " $imageName "
314+ podman run -d --user root - v " $PV " :/app --group-add " $groupId " --name " $AI " " $imageName "
320315 fi
321316
322317 podman exec " $AI " /bin/bash -c ' agent ido validate --config /app/data/conf/config.json; if [[ "$?" != "0" ]] ; then echo VALIDATE_FAILED > /app/data/conf/status.txt; else echo VALIDATE_SUCCESS > /app/data/conf/status.txt; fi ;'
@@ -820,12 +815,7 @@ upgrade()
820815
821816 # createDir changes the current working directory
822817 mkdir -p " ${PV} /upgrade"
823- if [ " $( podman --version 2> /dev/null) " ]
824- then
825- chmod -R 777 " ${PV} /upgrade" > /dev/null 2>&1
826- else
827- chmod -R 775 " ${PV} /upgrade" > /dev/null 2>&1
828- fi
818+ chmod -R 775 " ${PV} /upgrade" > /dev/null 2>&1
829819
830820 createDir " ${PV} /upgrade"
831821# shellcheck disable=SC2129
You can’t perform that action at this time.
0 commit comments