Repository navigation
Add AKS Defender for Containers quickstart - #498
Rebecca Calixte (Rebecca-Calixte) merged 3 commits into
Conversation
Co-authored-by: Rebecca-Calixte <262454636+Rebecca-Calixte@users.noreply.github.com>
Co-authored-by: vranade-microsoft <269690592+vranade-microsoft@users.noreply.github.com>
|
Summary of changes made using Copilot Root cause: The e2e-check job failed on Test_Quickstarts/quickstart/101-aks-defender-containers because the azurerm_security_center_subscription_pricing.containers resource's extension blocks for AgentlessVmScanning and ContainerSensor were declared without additional_extension_properties. Azure applies its own default properties for these extensions server-side (ExclusionTags for AgentlessVmScanning; AntiMalwareEnabled, AutoProvisioning, InstallationMethod, SecurityGatingEnabled for ContainerSensor), which aren't reflected in the Terraform config. This caused the idempotency check (second terraform plan after apply) to detect drift and fail with terraform configuration not idempotent. Fix: Added the matching additional_extension_properties to both extension blocks in quickstart/101-aks-defender-containers/main.tf so the plan is empty on re-apply. Code review found no issues, and CodeQL check was skipped since the change is trivial (adding attribute values only, no logic changes). |
Adds a Terraform quickstart sample for enabling Microsoft Defender for Containers on Azure Kubernetes Service (AKS).
This sample includes the Terraform configuration for enabling the Defender for Containers plan at the subscription level, creating an AKS cluster with Microsoft Defender security monitoring, and connecting the cluster to a Log Analytics workspace.
The README includes the original scenario’s prerequisites, deployment steps, verification steps, and resource cleanup guidance.