#!/usr/bin/env bash#set -x# Creates service principal with contributor role to your subscriptionSUBSCRIPTION_ID=$(azaccountshow--queryid-otsv)SP_NAME="firstContainerAppGitHubAction"azadspcreate-for-rbac--name $SP_NAME --role"contributor"--scopes"/subscriptions/$SUBSCRIPTION_ID"--sdk-auth--outputjsonservicePrincipalAppId=$(azadsplist--display-name $SP_NAME --query"[].appId"-otsv)azroleassignmentcreate--assignee $servicePrincipalAppId --role"User Access Administrator"--scopes"/subscriptions/$SUBSCRIPTION_ID"