You are designing deployments for Azure Container Instances (ACI) to host various workloads. You must configure the correct lifecycle management settings for each container group. Match each container workload scenario with the most appropriate container group restart policy.
- A containerized API gateway that routes incoming HTTP requests to backend microservices and must be highly available.Always
- A nightly data processing container that processes logs and must retry execution if it terminates with a non-zero exit code.OnFailure
- A one-time database schema migration script container that should never be re-run if it exits, regardless of the exit code, to prevent data corruption.Never
Answer
The API gateway matches the Always restart policy, the nightly log processing container matches the OnFailure restart policy, and the database schema migration script matches the Never restart policy.
The correct matches align with Azure Container Instances lifecycle designs. API gateways are long-running and require 'Always' to ensure continuous availability. Nightly data processors are run-to-completion tasks that should only rerun in the event of an abnormal exit, making 'OnFailure' the ideal configuration. Schema migrations are sensitive, one-time actions that must not restart under any circumstance, mapping to 'Never'.
Step-by-Step Solution
Key Concept
Azure Container Instances (ACI) restart policies govern the lifecycle behavior of container groups based on their workload type (Always, Never, or OnFailure).
Estimated Time:1m 35s