Compare commits

..

1 Commits

Author SHA1 Message Date
0b45c6adf1
chore(ci): add shellcheck
Some checks failed
commitlint / check-and-test (pull_request) Successful in 28s
Lint Shell files / shellcheck (pull_request) Failing after 1m51s
check-and-test / check-and-test (pull_request) Failing after 1m17s
2025-03-31 17:48:20 +02:00
2 changed files with 7 additions and 8 deletions

View File

@ -6,6 +6,10 @@ on:
types: [ "opened", "edited" ]
workflow_dispatch: {}
env:
# renovate: datasource=docker depName=koalaman/shellcheck
HELM_VERSION: "v0.10.0"
jobs:
shellcheck:
runs-on: ubuntu-latest

View File

@ -8,14 +8,9 @@ check_token() {
set +e
echo "Checking for existing token..."
if ! token=$(kubectl get secret "${SECRET_NAME}" -o jsonpath="{.data['token']}" 2> /dev/null); then
return 1
fi
if [ -z "${token}" ]; then
return 2
fi
token="$(kubectl get secret "$SECRET_NAME" -o jsonpath="{.data['token']}" 2> /dev/null)"
[ $? -ne 0 ] && return 1
[ -z "$token" ] && return 2
return 0
}