This is an automated email from the ASF dual-hosted git repository.
msciabarra pushed a commit to branch auth-check
in repository https://gitbox.apache.org/repos/asf/openserverless-task.git
The following commit(s) were added to refs/heads/auth-check by this push:
new 5e63150 reworked test auth check
5e63150 is described below
commit 5e63150d807934331a42283a3f15b878195ce0c0
Author: Michele Sciabarra <[email protected]>
AuthorDate: Tue Aug 5 12:15:15 2025 +0200
reworked test auth check
---
ide/opsfile.yml | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/ide/opsfile.yml b/ide/opsfile.yml
index 7822276..6c12165 100644
--- a/ide/opsfile.yml
+++ b/ide/opsfile.yml
@@ -36,10 +36,6 @@ tasks:
- test -e ~/.wskprops || die "please run 'ops ide login' first"
- test -n "$OPSDEV_HOST" || die "please run 'ops ide login' first"
- test "$(ops -wsk property get --namespace | awk '{ print $3 }')" =
"$OPSDEV_USERNAME" || die "Repeat the login"
- - |
- if test -n "$AUTH_CHECK"
- then test "$AUTH_CHECK" == "$AUTH" || die "You are logged in a
different user than your configured AUTH_CHECK"
- fi
- |
if ! test -d "$OPS_ROOT/ide/deploy/node_modules"
then cd $OPS_ROOT/ide/deploy && bun install
@@ -175,6 +171,11 @@ tasks:
if test -e $OPS_PWD/packages/.env
then source $OPS_PWD/packages/.env
fi
+ if test -n "$AUTH_CHECK"
+ then if test "$AUTH_CHECK" != "$AUTH"
+ then echo "You are logged in a different user than your
configured AUTH_CHECK" ; exit 1
+ fi
+ fi
if {{.__dry_run}}
then DRY="--dry-run" ; ECHO='echo'
else DRY="" ; ECHO=""
@@ -252,6 +253,11 @@ tasks:
if test -e $OPS_PWD/packages/.env
then source $OPS_PWD/packages/.env
fi
+ if test -n "$AUTH_CHECK"
+ then if test "$AUTH_CHECK" != "$AUTH"
+ then echo "You are logged in a different user than your
configured AUTH_CHECK" ; exit 1
+ fi
+ fi
if {{.__dry_run}}
then DRY="--dry-run" ; ECHO='echo'
else DRY="" ; ECHO=""