aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAmir Goldstein <amir73il@gmail.com>2022-08-18 10:15:23 +0300
committerTheodore Ts'o <tytso@mit.edu>2022-08-24 11:13:44 -0400
commit203909e2fb5710add44ba120ea789ab8a54d50d0 (patch)
tree48e7129afe31534f7bd59aebc6fe1d92999f5c65
parentfd78bd385ebe79382bdc5e6bdb7314f5a049b056 (diff)
downloadxfstests-bld-203909e2fb5710add44ba120ea789ab8a54d50d0.tar.gz
gce-xfstests: fix setup iam policy binding
On a new account setup. gce-xfstests setup failed with error: "Failed to add iam policy binding for roles/..." On the second (verbose) retry, the opertaion succeeds, but the script still aborts. Fix a typo in the first invocation of the command. Signed-off-by: Amir Goldstein <amir73il@gmail.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Link: https://lore.kernel.org/r/20220818071523.928417-1-amir73il@gmail.com
-rwxr-xr-xrun-fstests/util/gce-do-setup4
1 files changed, 2 insertions, 2 deletions
diff --git a/run-fstests/util/gce-do-setup b/run-fstests/util/gce-do-setup
index b99704a3..077b7d99 100755
--- a/run-fstests/util/gce-do-setup
+++ b/run-fstests/util/gce-do-setup
@@ -144,9 +144,9 @@ function SetupServiceAccount () {
--display-name "$name"
if ! run_gcloud projects add-iam-policy-binding "$GCE_PROJECT" \
--member "serviceAccount:$srv_acct" \
- --role "projects/$GCE_PROJECT/roles/$role" \
+ --role "$role" \
--verbosity none >& /dev/null ; then
- echo "Failed to add iam policy binding for roles/$role"
+ echo "Failed to add iam policy binding for role $role"
# Re-run to get error message
run_gcloud projects add-iam-policy-binding "$GCE_PROJECT" \
--member "serviceAccount:$srv_acct" \