Implement Azure Container Apps Flashcards

(30 cards)

1
Q

What is Azure container Apps (ACA)?

A
  • Enable you to run microservices and containerised apps on a serverless platform that runs on top of Azure Kubernetes service
  • Can dynamically scale based on HTTP traffic, event driven processing, CPU or memory load and any KEDA supported scaler
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What are common uses of ACA?

A
  • deploying API endpoints
  • hosting background processing apps
  • handling event driven processing
  • running microservices
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What can we do with ACA?

A
  • run multiple container revisions and manage the container apps lifecycle
  • autoscale apps
  • enable HTTP ingress without having to manage other infra
  • split traffic across multiple app versions
  • build microservices with Dapr
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is a container apps environment?

A
  • individual apps deployed to a single container apps env which acts as secure boundary around groups of container apps
  • apps in same env are deployed in same VN and write logs to same log analytics workspace
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What reasons would you have to deploy container apps to same env?

A
  • managed related services
  • deploy different apps to same VN
  • instrument Dapr apps that communicate via the Dapr API
  • Have apps to share Dapr config
  • have apps share same log analyitcs
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What reasons would you have to not deploy container apps to same env?

A
  • Ensure two apps never share same compute resources
  • ensure two Dapr apps cant communicate via Dapr API
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is the microservice architecture in relation to ACA?

A
  • allow you to independtly develop, upgrade, version and scale core areas of functionality in overall system
  • ACA provides independent scaling, service discovery and Dapr integration
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

How does networking work with microservices?

A
  • function calls spread across network
  • Need to account for failures, retries and timeouts
  • container app does feature building blocks for running microservices but Dapr provides even richer model
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What does Dapr include?

A
  • observability
  • pub/sub
  • service to service invocation with mutual TLS, retries and more
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

How does ACA manage container orchestration?

A
  • containers in ACA can use any runtime, programming lang or dev stack of your choice
  • supports any linux based x86-64 container image
  • No required base container image, if container crashes it auto restarts
  • changes to template ARM config section trigger a new container app revision
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is sidecar pattern?

A
  • Can define multiple containers in single container app
  • containers in the app share hard disk, network resource and experience same app lifecycle
  • e.g. agent that reads logs from primary container on a shared volume and forwards them to logging service
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

How can we manage private registers on ACA?

A
  • provide credentials in the container apps config to deploy images from private registers
  • to use a container registry you define the required feilds in the registries array in properties.configuration section of the container app resource template
    -passwordsecretRef field IDs the name of the secret in the secrets array where you defined the password
  • can then pull image from private reg
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What limiatons does ACA have?

A
  • privileged containers cannot be run in ACA = if program attempts to run process that requires root access, the app inside the container experiences a runtime error
  • OS = linux based container images only
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

How does ACA provide auth and auhorisation features?

A
  • built in features to secure external ingress-enabled apps with minimal or 0 code
  • dont require any particular lang SDK and work out the box
  • Only used with HTTPs
  • Ensure “AllowInSecure” is disabled on config
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

How does app access work with ACA?

A
  • RequireAuthentication = only authenticated users can access app
  • AllowUnauthorisedAccess = authenticates but doesnt restrict access
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is federated ID?

A
  • Third party ID provider used by ACA
  • manages user ID and auth flow for you
  • github, facebook, AAD, google, twitter and openID supported
17
Q

What is the auth and authorization middleware in ACA?

A
  • runs as a sidecar container on each replica in your app
  • when enabled every incoming HTTP request passes through security layer b4 app
  • handles auth of session, authenticates users and clients and injects info into HTTP request headers
18
Q

How does auth flow work in ACA with and without provider SDK?

A
  • with = app signs users into provider manually and submits auth token to container apps for validation (used in browserless apps and native mobile apps)
  • without = app delegates federated sign-in to container apps (used in browser apps which present the providers sign-in page to users
19
Q

What are app revisions in ACA?

A
  • revision is an immutable snapshot of a container app version
  • can use to release a new version of app or quickly revert to previous version
  • new revisions created when you update app with revision scope changes
  • can control which revisions are active and the traffic that is routed to each one
20
Q

How does ACA revision naming work?

A
  • by default ACA creates a unique revision name with a suffix consisting of a semi-random string of alphanumeric chars
  • e.g. container app names album-api would create a revision album-api-1st-revision
21
Q

What command allows you to update ACA containers?

A
  • “az containerapp update” cmd allows you to modify env vars, compute resources, scale params and deployment of different images to container app
22
Q

How does ACA handle secrets?

A
  • Once secrets are defined at app level, secured values are available to container apps
  • scoped to app rather than revision
  • adding, removing or changing secrets doesnt generate a new revision, will need to manually deploy one or restart existing one
  • each revision can reference one or more secrets
  • multiple revisions can ref same secret
  • secrets defined with “–secrets” param, can then be accessed via env vars
23
Q

What is Dapr?

A
  • set of incrementally adoptable features that simplify the authoring of distributed, microservice apps
  • provides capabilities for enabling app communication through pub/sub msgs or reliable and secure service-service calls
24
Q

What is CNCF?

A
  • Cloud Native Computing Foundation
  • Part of linux foundation and provides support, oversight and direction for fast growing cloud native projects
  • Dapr is part of CNCF
25
How does ACA integrate with Dapr?
- Provides managed supported Dapr integration - Handles Dapr version upgrades seamlessly - Exposes simplified Dapr interaction model to incease dev productivity
26
Core features of Dapr?
- Service-service invocation - State management - pub/sub - bindings (triggers) - actors (message driven single threaded units of work designed to quickly scale) - observability - secrets (can be accessed through code)
27
What are container apps with Dapr enabled?
- Dapr is enabled at the container app level by configuring a set of dapr args - values apply to all revisions of a given container app when running in multiple revisions mode
28
What is just pure Dapr mode in ACA?
- fully managed Dapr APIs are exposed to each container app through Dapr sidecar - APIs can be invoked from container app via HTTP - sidecar runs on HTTP port 3500
29
What is Dapr component configuration?
- Dapr uses a modular design where functionality is delivered as a component - components can be shared across multiple container apps - Dapr IDs provided in the scopes array dictates which dapr enabled container apps load a given component at runtime
30
Which channels does ACA provide for configuring dapr?
- Container apps CLI - IaaC templates such as ARM and bicep - Portal