sigs.k8s.io/cluster-api-provider-aws@v1.5.5/test/e2e/data/infrastructure-aws/e2e_test_templates/cluster-template-multi-az.yaml (about)

     1  apiVersion: cluster.x-k8s.io/v1beta1
     2  kind: Cluster
     3  metadata:
     4    labels:
     5      cni: ${CLUSTER_NAME}-crs-0
     6    name: ${CLUSTER_NAME}
     7  spec:
     8    clusterNetwork:
     9      pods:
    10        cidrBlocks:
    11        - 192.168.0.0/16
    12    controlPlaneRef:
    13      apiVersion: controlplane.cluster.x-k8s.io/v1beta1
    14      kind: KubeadmControlPlane
    15      name: ${CLUSTER_NAME}-control-plane
    16    infrastructureRef:
    17      apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
    18      kind: AWSCluster
    19      name: ${CLUSTER_NAME}
    20  ---
    21  apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
    22  kind: AWSCluster
    23  metadata:
    24    name: ${CLUSTER_NAME}
    25  spec:
    26    network:
    27      subnets:
    28      - availabilityZone: ${AWS_AVAILABILITY_ZONE_1}
    29        cidrBlock: 10.0.0.0/24
    30      - availabilityZone: ${AWS_AVAILABILITY_ZONE_1}
    31        cidrBlock: 10.0.1.0/24
    32        isPublic: true
    33      - availabilityZone: ${AWS_AVAILABILITY_ZONE_2}
    34        cidrBlock: 10.0.2.0/24
    35      - availabilityZone: ${AWS_AVAILABILITY_ZONE_2}
    36        cidrBlock: 10.0.3.0/24
    37        isPublic: true
    38    region: ${AWS_REGION}
    39    sshKeyName: ${AWS_SSH_KEY_NAME}
    40  ---
    41  apiVersion: controlplane.cluster.x-k8s.io/v1beta1
    42  kind: KubeadmControlPlane
    43  metadata:
    44    name: ${CLUSTER_NAME}-control-plane
    45  spec:
    46    kubeadmConfigSpec:
    47      clusterConfiguration:
    48        apiServer:
    49          extraArgs:
    50            cloud-provider: aws
    51        controllerManager:
    52          extraArgs:
    53            cloud-provider: aws
    54      initConfiguration:
    55        nodeRegistration:
    56          kubeletExtraArgs:
    57            cloud-provider: aws
    58          name: '{{ ds.meta_data.local_hostname }}'
    59      joinConfiguration:
    60        nodeRegistration:
    61          kubeletExtraArgs:
    62            cloud-provider: aws
    63          name: '{{ ds.meta_data.local_hostname }}'
    64    machineTemplate:
    65      infrastructureRef:
    66        apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
    67        kind: AWSMachineTemplate
    68        name: ${CLUSTER_NAME}-control-plane
    69    replicas: ${CONTROL_PLANE_MACHINE_COUNT}
    70    version: ${KUBERNETES_VERSION}
    71  ---
    72  apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
    73  kind: AWSMachineTemplate
    74  metadata:
    75    name: ${CLUSTER_NAME}-control-plane
    76  spec:
    77    template:
    78      spec:
    79        iamInstanceProfile: control-plane.cluster-api-provider-aws.sigs.k8s.io
    80        instanceType: ${AWS_CONTROL_PLANE_MACHINE_TYPE}
    81        sshKeyName: ${AWS_SSH_KEY_NAME}
    82  ---
    83  apiVersion: cluster.x-k8s.io/v1beta1
    84  kind: MachineDeployment
    85  metadata:
    86    name: ${CLUSTER_NAME}-md-0
    87  spec:
    88    clusterName: ${CLUSTER_NAME}
    89    replicas: ${WORKER_MACHINE_COUNT}
    90    selector:
    91      matchLabels: null
    92    template:
    93      spec:
    94        bootstrap:
    95          configRef:
    96            apiVersion: bootstrap.cluster.x-k8s.io/v1beta1
    97            kind: KubeadmConfigTemplate
    98            name: ${CLUSTER_NAME}-md-0
    99        clusterName: ${CLUSTER_NAME}
   100        infrastructureRef:
   101          apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
   102          kind: AWSMachineTemplate
   103          name: ${CLUSTER_NAME}-md-0
   104        version: ${KUBERNETES_VERSION}
   105  ---
   106  apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
   107  kind: AWSMachineTemplate
   108  metadata:
   109    name: ${CLUSTER_NAME}-md-0
   110  spec:
   111    template:
   112      spec:
   113        iamInstanceProfile: nodes.cluster-api-provider-aws.sigs.k8s.io
   114        instanceType: ${AWS_NODE_MACHINE_TYPE}
   115        sshKeyName: ${AWS_SSH_KEY_NAME}
   116  ---
   117  apiVersion: bootstrap.cluster.x-k8s.io/v1beta1
   118  kind: KubeadmConfigTemplate
   119  metadata:
   120    name: ${CLUSTER_NAME}-md-0
   121  spec:
   122    template:
   123      spec:
   124        joinConfiguration:
   125          nodeRegistration:
   126            kubeletExtraArgs:
   127              cloud-provider: aws
   128            name: '{{ ds.meta_data.local_hostname }}'
   129  ---
   130  apiVersion: v1
   131  data: ${CNI_RESOURCES}
   132  kind: ConfigMap
   133  metadata:
   134    name: cni-${CLUSTER_NAME}-crs-0
   135  ---
   136  apiVersion: addons.cluster.x-k8s.io/v1beta1
   137  kind: ClusterResourceSet
   138  metadata:
   139    name: ${CLUSTER_NAME}-crs-0
   140  spec:
   141    clusterSelector:
   142      matchLabels:
   143        cni: ${CLUSTER_NAME}-crs-0
   144    resources:
   145    - kind: ConfigMap
   146      name: cni-${CLUSTER_NAME}-crs-0
   147    strategy: ApplyOnce