Skip to content
Snippets Groups Projects
Commit adc2c94b authored by nimrod's avatar nimrod
Browse files

Small fix to assume-role.

parent e3bc5061
Branches
No related tags found
No related merge requests found
...@@ -20,7 +20,7 @@ fi ...@@ -20,7 +20,7 @@ fi
role="$1" role="$1"
shift shift
if [ "$(aws iam list-mfa-devices --query 'length(MFADevices)')" -gt 0 ] if mfa_count="$(aws iam list-mfa-devices --query 'length(MFADevices)' 2>/dev/null)" && [ "$mfa_count" -gt 0 ]
then then
printf "Enter the MFA token: " printf "Enter the MFA token: "
read -r mfa_token read -r mfa_token
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment