How azure/aks-engine works
AKS Engine is a CLI for provisioning and operating self-managed Kubernetes clusters on Azure (with Azure Stack support noted in the repository status). Its user-facing commands cover deployment, scaling, upgrades, and certificate rotation; internally, API models and the template engine describe clusters and Azure resources, while ARM and Kubernetes clients support cluster operations. The sampled files show the CLI entry point, template-generation code, storage-resource construction, and parts of certificate rotation and upgrade behavior. Several command-to-subsystem links are therefore shown as unverified rather than asserted as inspected calls.
Main entry points: root.go Command dispatch · types.go Cluster API model · deploy.go Deploy cluster · rotate_certs.go Rotate certificates
Components 22
CLI commands
- CLI entry
main.go - Command dispatch
cmd/root.go - Deploy cluster
cmd/deploy.go - Scale pool
cmd/scale.go - Upgrade cluster
cmd/upgrade.go - Rotate certificates
cmd/rotate_certs.go
Cluster model
- Cluster API model
pkg/api/types.go - Orchestrator versions
pkg/api/orchestrators.go - Kubernetes defaults
pkg/api/defaults-controller-manager.go
Provisioning
- Template engine
pkg/engine/engine.go - ARM resource templates
pkg/engine/storageaccounts.go - Model transformation
pkg/engine/transform/transform.go
Cluster operations
- Rotation operations
cmd/rotatecerts/operations.go - Rotation wait
cmd/rotatecerts/wait.go - Upgrade workflow
pkg/operations/kubernetesupgrade/upgrader.go - Cluster upgrade
pkg/operations/kubernetesupgrade/upgradecluster.go - VM operations
pkg/operations/deletevm.go
Cloud clients
- Azure resource client
pkg/armhelpers/azureclient.go - Azure Stack client
pkg/armhelpers/azurestack/azureclient.go - Kubernetes client
pkg/kubernetes/client.go - Composite client
pkg/kubernetes/composite_client.go
Other components
- Operator
Connections 25
- Operator → CLI entry: runs
main.go - CLI entry → Command dispatch: executes
main.go - Command dispatch → Deploy cluster: dispatches
- Command dispatch → Scale pool: dispatches
- Command dispatch → Upgrade cluster: dispatches
- Command dispatch → Rotate certificates: dispatches
- Deploy cluster → Cluster API model: loads model
- Deploy cluster → Template engine: generates templates
- Deploy cluster → Azure resource client: deploys resources
- Scale pool → Template engine: builds resources
- Scale pool → VM operations: operates VMs
- Upgrade cluster → Upgrade workflow: starts upgrade
- Upgrade workflow → Cluster upgrade: coordinates
- Upgrade workflow → Kubernetes client: uses
- Upgrade workflow → Azure resource client: uses
- Rotate certificates → Rotation operations: coordinates
- Rotate certificates → Rotation wait: waits via
- Rotate certificates → Kubernetes client: accesses cluster
- Cluster API model → Kubernetes defaults: applies defaults
- Orchestrator versions → Cluster API model: provides versions
- Template engine → ARM resource templates: creates resources
- Template engine → Cluster API model: consumes model
- Model transformation → Cluster API model: transforms model
- Azure resource client → Azure Stack client: has Stack variant
- Composite client → Kubernetes client: wraps clients