mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-04-22 16:19:19 -04:00
ci: query identity directly instead of searching in list
This commit is contained in:
parent
5684108eb0
commit
c8cfb25008
6
.github/actions/cdbg_deploy/action.yml
vendored
6
.github/actions/cdbg_deploy/action.yml
vendored
@ -40,10 +40,10 @@ runs:
|
||||
if: inputs.cloudProvider == 'azure'
|
||||
shell: bash
|
||||
run: |
|
||||
UAMI=$(yq eval ".provider.azure.userAssignedIdentity | upcase" constellation-conf.yaml)
|
||||
PRINCIPAL_ID=$(az identity list | yq ".[] | select(.id | test(\"(?i)$UAMI\"; \"g\")) | .principalId")
|
||||
UAMI=$(yq eval ".provider.azure.userAssignedIdentity" constellation-conf.yaml)
|
||||
PRINCIPAL_ID=$(az identity show --ids "$UAMI" | yq ".principalId")
|
||||
if [ -z "$PRINCIPAL_ID" ]; then
|
||||
echo "::error::PRINCIPAL_ID for $UAMI not found"
|
||||
echo "::error::PRINCIPAL_ID for \"$UAMI\" not found"
|
||||
echo "::group::Available identities"
|
||||
az identity list | yq ".[].id"
|
||||
echo "::endgroup::"
|
||||
|
Loading…
x
Reference in New Issue
Block a user