Skip to content

Instantly share code, notes, and snippets.

@sathishjayapal
Last active June 20, 2022 03:04
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sathishjayapal/8d03d56c45f9d0039a3674207e0f2bc3 to your computer and use it in GitHub Desktop.
Save sathishjayapal/8d03d56c45f9d0039a3674207e0f2bc3 to your computer and use it in GitHub Desktop.

AZ- Service principal commands

Loging with service principal credentials. Remember the tenant parameter

az login --service-principal -u -p --tenant

List the role definitions - List all the role definitions

az role definition list --all

List the role assignments - Lists all the role assignments

az role assignment list --all

You can find the same information by running the following command in the Cloud Shell. They are listed in the Additional Outbound IP Addresses field.

az webapp show
--resource-group <group_name>
--name <app_name>
--query outboundIpAddresses
--output tsv

To find all possible outbound IP addresses for your app, regardless of pricing tiers, run the following command in the Cloud Shell.

az webapp show
--resource-group <group_name>
--name <app_name>
--query possibleOutboundIpAddresses
--output tsv

List out all the rg that matches rg name az104

az group list --query "[?contains(name, 'az104-rg')].[name]" --output tsv resourceGroup=$(az group list --query "[?contains(name, 'az104-rg')].[name]" --output tsv)

Flapping

Estimation during a scale-in is intended to avoid "flapping" situations, where scale-in and scale-out actions continually go back and forth. Keep this behavior in mind when you choose the same thresholds for scale-out and in.

To let users opt out of your beta app, for example, you can put this link on your webpage:

Go back to production app The string x-ms-routing-name=self specifies the production slot. After the client browser accesses the link, it's redirected to the production slot. Every subsequent request has the x-ms-routing-name=self cookie that pins the session to the production slot.

Webjobs

Like Azure Functions, Azure App Service WebJobs with the WebJobs SDK is a code-first integration service that is designed for developers. Both are built on Azure App Service and support features such as source control integration, authentication, and monitoring with Application Insights integration.

@sathishjayapal
Copy link
Author

AZ Challenge notes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment