How does GitOps work on AKS with the Flux extension?
IntermediateConceptAKS and ACR
Answer
The microsoft.flux cluster extension installs Flux v2, and a fluxConfiguration resource points the cluster at a git repo, branch and kustomization paths:
az k8s-configuration flux create -g rg -c aks -t managedClusters \
-n shop --namespace flux-system --scope cluster \
-u https://github.com/devopsshack/shop-gitops --branch main \
--kustomization name=apps path=./clusters/prod prune=true
The configuration is an Azure resource, so it can be deployed by Bicep/Terraform and assigned at scale via Azure Policy across many clusters. Argo CD is the alternative many teams self-install (and an AKS extension for Argo CD has been in preview).
More on AKS and ACR
What does Microsoft manage in AKS and what do you manage?BeginnerWhat is the difference between system and user node pools?BeginnerCompare the AKS networking options: kubenet, Azure CNI, Azure CNI Overlay, Azure CNI Powered by Cilium.AdvancedHow many IPs does an AKS subnet need with flat Azure CNI vs Overlay?AdvancedWhat are the AKS tiers (Free, Standard, Premium)?IntermediateHow do AKS Kubernetes version upgrades work?Intermediate