Skip to content

Commit

Permalink
use sufficient identity roles for conformance tests (#5060)
Browse files Browse the repository at this point in the history
* use sufficient identity roles for conformance tests

Signed-off-by: Jack Francis <[email protected]>

* test original solution

Signed-off-by: Jack Francis <[email protected]>

* remove storage account contrib

Signed-off-by: Jack Francis <[email protected]>

* try Reader-only

Signed-off-by: Jack Francis <[email protected]>

* try Contributor instead of Owner

Signed-off-by: Jack Francis <[email protected]>

* add RBAC role

Signed-off-by: Jack Francis <[email protected]>

---------

Signed-off-by: Jack Francis <[email protected]>
  • Loading branch information
jackfrancis authored Aug 9, 2024
1 parent dbbf684 commit 5b802a0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/kind-with-registry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -159,13 +159,13 @@ EOF
AZURE_IDENTITY_ID_PRINCIPAL_ID=$(az identity show -n "${USER_IDENTITY}" -g "${AZWI_RESOURCE_GROUP}" --query principalId -o tsv)

echo "${AZURE_IDENTITY_ID}" > "${AZURE_IDENTITY_ID_FILEPATH}"
until az role assignment create --assignee-object-id "${AZURE_IDENTITY_ID_PRINCIPAL_ID}" --role "Owner" --scope "/subscriptions/${AZURE_SUBSCRIPTION_ID}" --assignee-principal-type ServicePrincipal; do
until az role assignment create --assignee-object-id "${AZURE_IDENTITY_ID_PRINCIPAL_ID}" --role "Contributor" --scope "/subscriptions/${AZURE_SUBSCRIPTION_ID}" --assignee-principal-type ServicePrincipal; do
sleep 5
done
until az role assignment create --assignee-object-id "${AZURE_IDENTITY_ID_PRINCIPAL_ID}" --role "Storage Account Contributor" --scope "/subscriptions/${AZURE_SUBSCRIPTION_ID}" --assignee-principal-type ServicePrincipal; do
until az role assignment create --assignee-object-id "${AZURE_IDENTITY_ID_PRINCIPAL_ID}" --role "Role Based Access Control Administrator" --scope "/subscriptions/${AZURE_SUBSCRIPTION_ID}" --assignee-principal-type ServicePrincipal; do
sleep 5
done
until az role assignment create --assignee-object-id "${AZURE_IDENTITY_ID_PRINCIPAL_ID}" --role "Storage Blob Data Owner" --scope "/subscriptions/${AZURE_SUBSCRIPTION_ID}" --assignee-principal-type ServicePrincipal; do
until az role assignment create --assignee-object-id "${AZURE_IDENTITY_ID_PRINCIPAL_ID}" --role "Storage Blob Data Reader" --scope "/subscriptions/${AZURE_SUBSCRIPTION_ID}" --assignee-principal-type ServicePrincipal; do
sleep 5
done

Expand Down

0 comments on commit 5b802a0

Please sign in to comment.