From 7aa255f4dd8cde968ea91d4329c8dad2636b439c Mon Sep 17 00:00:00 2001 From: Arnaud Lheureux Date: Sat, 30 Jan 2021 11:57:06 +0800 Subject: [PATCH] Update functions.sh --- scripts/functions.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/functions.sh b/scripts/functions.sh index 6ab70f9d..bcadff62 100644 --- a/scripts/functions.sh +++ b/scripts/functions.sh @@ -176,7 +176,7 @@ function verify_azure_session { function check_subscription_required_role { echo "@checking if current user (object_id: ${TF_VAR_logged_user_objectId}) is ${1} of the subscription - only for launchpad" - role=$(az role assignment list --role "${1}" --assignee ${TF_VAR_logged_user_objectId}) + role=$(az role assignment list --role "${1}" --assignee ${TF_VAR_logged_user_objectId} --include-inherited --include-groups) if [ "${role}" == "[]" ]; then error ${LINENO} "the current account must have ${1} privilege on the subscription to deploy launchpad." 2 @@ -1073,4 +1073,4 @@ function process_target_subscription { echo "Tfstates subscription set to ${TF_VAR_tfstate_subscription_id} (${tfstate_subscription_name})" echo "" -} \ No newline at end of file +}