The following project demonstrates deployment of a private AKS cluster within a hub-spoke model with BYO Private DNS Zone. It consists of:
- Hub VNET with:
- Azure Bastion - Used SSH into BIND/Jump Box VMs/AKS Nodes
- Azure Firewall - Used for AKS Egress Filtering
- BIND DNS - Used as the DNS for Spoke VNET, Forwards to 168.63.129.16 for Private Endpoint resolution
- Private Endpoint Subnet for ACR/other shared resources
- Azure Private DNS for Private Endpoints [ACR, AKS]
- Spoke VNET with:
As there are multiple ways to create TF modules and instantiate environment instances. I structured the repository in the following way:
- Single resources and their dependencies are grouped into a module
- Architecture templates are grouped into a module
- There is only 2 degrees of nesting max: root main.tf --> module --> module
- Terraform execution environment could be windows or linux based.
- Leverage the azure cli login auth method within your dev environment.
- Ensure you edit the bind_install.sh to reference your own blob storage location for config file storage and update named.conf.options allowedclients list.
- Generate PEM keys for VMs and AKS
To generate an ssh key pair for VM/AKS access, you can leverage the following command: ssh-keygen -m PEM -t rsa -b 4096 -f "key name" Make sure to reference the right pem key location within your tfvars
Azure Bastion host will be leveraged to SSH into VMs within the environment [ex. DNS Server, Jump Boxes and AKS nodes].
