After you are done exploring your deployed AKS secure baseline cluster, you'll want to delete the created Azure resources to prevent undesired costs from accruing. Follow these steps to delete all resources created as part of this reference implementation.
-
Delete the resource groups, which will delete all related Azure resources.
⚠️ Ensure you are using the correct subscription, and validate that the only resources that exist in these groups are ones you're okay deleting.az group delete -n rg-shipping-dronedelivery-${LOCATION} --no-wait az group delete -n rg-shipping-dronedelivery-${LOCATION}-acr --no-wait az group delete -n rg-enterprise-networking-spokes-${LOCATION} --no-wait az group delete -n rg-enterprise-networking-hubs-${LOCATION} --no-wait
-
Purge Azure Key Vault
Because this reference implementation enables soft delete on Key Vault, execute a purge, so your next deployment of this implementation doesn't run into a naming conflict.
az keyvault purge --name ${KEYVAULT_NAME} --location eastus2
-
If any temporary changes were made to Microsoft Entra ID or Azure RBAC permissions, consider removing those as well.
-
If a service principal was created as part of the GitHub Action integration, consider removing it as well.
-
Remove the Azure Policy assignments scoped to the cluster's resource group. To identify those created by this implementation, look for ones that are prefixed with
[your-cluster-name]
.