diff --git a/ic-os/components/ic/setup-permissions/erestorecon.sh b/ic-os/components/ic/setup-permissions/erestorecon.sh index 3cc9a4192e5..876c59f9af5 100755 --- a/ic-os/components/ic/setup-permissions/erestorecon.sh +++ b/ic-os/components/ic/setup-permissions/erestorecon.sh @@ -5,4 +5,4 @@ set -e # erestorecon (easy prestorecon) uses UNIX tools to parallelize restorecon, # instead of the cpp based prestorecon. -find $@ -print0 | xargs -0 -P 0 restorecon +find $@ -print0 | xargs -0 -P 0 restorecon -F diff --git a/ic-os/components/ic/setup-permissions/setup-permissions.sh b/ic-os/components/ic/setup-permissions/setup-permissions.sh index 8576d1e1e60..9b073af4954 100755 --- a/ic-os/components/ic/setup-permissions/setup-permissions.sh +++ b/ic-os/components/ic/setup-permissions/setup-permissions.sh @@ -24,8 +24,8 @@ function make_group_owned_and_sticky() { local GROUP="$3" mkdir -p "${TARGET_DIR}" - chown -R "${USER}:${GROUP}" "${TARGET_DIR}" - chmod u=rwX,g=rX,o= -R "${TARGET_DIR}" + find "${TARGET_DIR}" -print0 | xargs -0 -P 0 chown "${USER}:${GROUP}" + find "${TARGET_DIR}" -print0 | xargs -0 -P 0 chmod u=rwX,g=rX,o= find "${TARGET_DIR}" -type d | xargs chmod g+s }