Azure Kubernetes Service (AKS) Workshop
- Azure subscription with
Owner
role- Why? Because we need to assign permissions e.g.,
AcrPull
and others
- Why? Because we need to assign permissions e.g.,
- Azure subscription should be enabled for creating following resources:
- Multiple Azure Virtual Networks
- User Defined Routes (UDR)
- Network Security Groups (NSG)
- Private DNS Zone
- Virtual Machine
- Bastion Host
- Azure Container Registry (ACR)
- Azure Kubernetes Service (AKS)
- Azure Container Instances (ACI)
- Azure Storage Account
- NFS fileshare
- Private endpoint
- Azure Application Gateway
- Azure Log Analytics Workspace
- Multiple Azure Virtual Networks
- Each person should have their own dedicated resource group
- Why? Because we need to test AKS cluster upgrades and other operations that require personal environments
- Azure Cloud Shell available
- Entra ID Group that contains all workshop participants
- Why? Because we need have group for AKS cluster admin access
- You only need to have
Object ID
of the group - You can use My Groups
to find group that you're member of. You can see
Object ID
of the group in URL.
- You only need to have
- Why? Because we need have group for AKS cluster admin access
- Open Azure Cloud Shell
- Use
Bash
- Use clouddrive folder for persisting files in Azure Cloud Shell
- To prevent cloud shell for timing out, you can use following
keep_alive
trick in00-variables.sh
script:
- Use
while :; do echo 'Hit CTRL+C'; sleep 1; done
- If cloud shell does timeout, then you can recover variable state using these steps:
- Run
00-variables.sh
to restore variable values - Update authorized IP ranges to AKS:
my_ip=$(curl -s https://myip.jannemattila.com) az aks update -g $resource_group_name -n $aks_name --api-server-authorized-ip-ranges $my_ip
- Get credentials for connecting to AKS:
az aks get-credentials -n $aks_name -g $resource_group_name --overwrite-existing
- Test connectivity to API Server:
kubectl get nodes
- Run
- Alternative environment options: Use WSL or Linux
- Pre-reqs for alternative environment:
- Azure CLI
- Optional VS Code
- Execute different script steps one-by-one in VS Code (hint: use shift-enter)
- Clone this repo
git clone https://github.com/JanneMattila/aks-workshop.git
- Good idea to clone this also to local machine for better readability and usability
- Start deployments by opening 00-variables.sh and follow the instructions