-
Notifications
You must be signed in to change notification settings - Fork 431
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
59 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
templates/flavors/default/patches/azure-cluster-vnet-subnet-cidrs.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureCluster | ||
metadata: | ||
name: ${CLUSTER_NAME} | ||
spec: | ||
networkSpec: | ||
apiServerLB: | ||
# We pre-create this public IP and the DNS name to use it in the | ||
# worker node's /etc/hosts. | ||
frontendIPs: | ||
- name: ${CLUSTER_NAME}-api-lb | ||
publicIP: | ||
name: ${CLUSTER_NAME}-api-lb | ||
dnsName: ${CLUSTER_NAME}-${APISERVER_LB_DNS_SUFFIX}.${AZURE_LOCATION}.cloudapp.azure.com | ||
- name: ${CLUSTER_NAME}-internal-lb-ip | ||
privateIP: 10.0.0.100 | ||
vnet: | ||
cidrBlocks: | ||
- 10.0.0.0/16 | ||
subnets: | ||
- name: control-plane-subnet | ||
role: control-plane | ||
cidrBlocks: | ||
- 10.0.0.0/24 | ||
- 10.0.1.0/24 | ||
- name: node-subnet | ||
role: node | ||
cidrBlocks: | ||
- 10.0.2.0/24 | ||
- 10.0.3.0/24 | ||
- 10.0.4.0/24 |
13 changes: 13 additions & 0 deletions
13
templates/flavors/default/patches/kubeadm-config-template-worker-node.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 | ||
kind: KubeadmConfigTemplate | ||
metadata: | ||
name: "${CLUSTER_NAME}-md-0" | ||
spec: | ||
template: | ||
spec: | ||
# /etc/hosts file is updated with a pre-created DNS name of the API server and internal load-balancer's IP. | ||
# This custom DNS Resolution of the API server ensures that the worker nodes can reach the API server when | ||
# the public IP of the API server is not accessible. | ||
# 10.0.0.100 is the default IP that gets assigned to an internal load balancer. | ||
preKubeadmCommands: | ||
- echo '10.0.0.100 ${CLUSTER_NAME}-${APISERVER_LB_DNS_SUFFIX}.${AZURE_LOCATION}.cloudapp.azure.com' >> /etc/hosts |