From d2dc6e4cdae515e6a5bee4e5c9cfb7f57c417d5a Mon Sep 17 00:00:00 2001 From: Amol Kahat Date: Wed, 4 Jan 2023 18:22:56 +0530 Subject: [PATCH] Fix syntax error in uid_gid_manage.sh file Related-Bug: #2001626 Signed-off-by: Amol Kahat Change-Id: I53fa23723db0a334b2afb58e0a381439ac535a74 --- container-images/kolla/base/uid_gid_manage.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/container-images/kolla/base/uid_gid_manage.sh b/container-images/kolla/base/uid_gid_manage.sh index 4975fbc81..81c7d47ad 100755 --- a/container-images/kolla/base/uid_gid_manage.sh +++ b/container-images/kolla/base/uid_gid_manage.sh @@ -116,7 +116,7 @@ for _USER_TO_CREATE in $_USERS_TO_CREATE; do _EXTRA_PERMS="&& mkdir -p $_HOME_DIR && chown -R $_UID:$_GID $_HOME_DIR" fi # --append only exists with usermod - [ ! -z $_EXTRA_GROUPS_ARG ] && _EXTRA_GROUPS_ARG="--append $_EXTRA_GROUPS_ARG" + [[ ! -z $_EXTRA_GROUPS_ARG ]] && _EXTRA_GROUPS_ARG="--append $_EXTRA_GROUPS_ARG" _USERADD_CMD="usermod ${_HOME_ARGS} --gid $_GID --uid $_UID ${_EXTRA_GROUPS_ARG} $_NAME ${_EXTRA_PERMS}" else _USERADD_CMD="useradd -l ${_HOME_ARGS} --shell /usr/sbin/nologin --uid $_UID --gid $_GID ${_EXTRA_GROUPS_ARG} $_NAME"