Develop Azure compute solutions Flashcards
What is Azure App Service?
An HTTP-based service for hosting web applications, REST APIs, and mobile back ends.
What are the two built in auto scale support for web apps? Which is preferred?
Scale up / down refers to scaling hardware. Cores, and memory. Scaling out refers to adding more machines to the process.
Azure Apps support scale out / in.
How can you deploy an app with Azure Web apps?
Through integration with Azure DevOps, GitHub, Bitbucket, or even a local repository.
What are Deployment slots?
Allow for deploying code without having to shut down production, being able to swap to the new code and back if needed.
Must be Standard, Premium, or Isolated tier
What pricing tiers are there for web apps?
Shared, Free, Standard, Premium, PremiumV2, PremiumV3, Isolated
Consumption for function apps.
How would you deploy an app to Azure with the Azure CLI?
az webapp up - app name –resource-group azResourceGroup
Types of authentication available to web apps?
You can use built in in your code, but there are a number of identity providers: /.auth/login/aad - Azure Active Director /.auth/login/facebook /.auth/login/google /.auth/login/twitter /.aut/login/ - OpenID Connect
What are the ways you can control authorization in azure web apps?
Allow unauthenticated requests - Allows the passing of http headers, providing flexibility in handling anonymous requests.
Require authentication - reject any unauthenticated traffic to your application.
What is multitenant public service?
This allows for apps to be accessible on internet-hosted endpoints. Available on all service plans, except for isolated in which there is single tenant sign in.
To find in azure properties: possibleOutboundAddresses
Or in azure cli: az webapp show \ --resource-group \ --name \ --query outboundIpAddresses \ --output tsv
Where are applications settings found in webapps?
In ASP.NET it’s either WEb.config or appsettings.json
This can house things such as connection strings.
How can you configure path mappings?
In windows you can add a “new handler” - this allows for file extension, script processor, and arguments.
Linux and containerized apps can also be configured with an azure Storage mount.
What type of logging can you have from app services?
Application logging - app service file system and / or azure storage blobs
Web server logging - App service system or Azure storage blobs
Detailed error logging - App service File
Failed request tracing - App service file
Deployment logging - App service file
How can you view log streams in Azure CLI?
az webapp log tail –name appname –resource-group myResourceGroup
How can you configure security certificates in azure app service?
- Create a free app service managed certificate
- Must be basic, standard, premium, or isolated tier
- Purchase an App service certificate
- Import a certificate from Key Vault
- Upload a private certificate
- Upload a public certificate
What is a feature flag?
A binary state of on or off that you can use in code to tell which operation should happen, as an environment variable from the azure app service.
Feature manager helps to support feature flags. Managed in appsettings.json
What is an autoscaling rule? What plans support autoscaling?
A rule decision that tells you when to add or remove resources to the web app.
Not free or shared. Must be at least S1 or any P level tiers.
What is slot swapping? What are the steps involved?
Swapping from maybe staging to production in deployment slots.
- Apply settings from the target slow
- Wait for every instance in source slot to restart, otherwise revert.
- Trigger local cache initialization
- If customwarm-up, trigger application initiation by making an HTTP request.
- Once a slot is warmed up, swap the two slots.
- Perform the same operation of settings on the source slot.
Can you route traffic between deployment slots?
Yes, you can. By default 0% of traffic routed to new deployment slots.
Define Azure Functions
Simple web serverless apis. They can support :
- Triggers
- bindings
- Input data
- Output data
What are the differences between logic apps and azure functions?
Azure functions are code-first, where as logic apps are designer first.
Logic apps have a large collection of connectors, more than azure functions.
Logic apps have ready made actions.
Functions vs Webjobs
Webjobs are not serverless, and unlike functions are not pay per use, or having intergration with logic apps.
Can all tiers of Azure functions scale?
No - only consumption and premium tiers can. Dedicated do not scale.
Trigger events for Azure Functions
Timer Azure Storage queues and blobs Azure service bus queues and topics Azure Cosmos DB Azure Event Hubs HTTP/Webhook Azure Event Grid
Where are function’s trigger, bindings, and settings configured? What does it typically look like?
In the function.json file. Bindings have type, direction, and name.
What is a function with stateful attributes called?
A durable function.
Why would you use a durable function
If you need:
- Function chaining
- Fan-out/fan-in
- Async HTTP apis
- Monitor
- Human interaction
What is an ARM?
Azure Resource management template used to deploy azure resources programmatically.
What are the IaaS solutions? What are the key areas?
Azure VMs.
Managed identities - how can you assign one to a virtual machine? System and user?
* Try to use powershell for getting the credential and token for the identity.
- Backup and restore approaches
- Accelerated Networking - things like vNets - not across region
- When not to use an Azure VM
What are the steps to deploying an Azure web app?
- Create an app service plan
- Create an app
- Deploy code