-
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.
Add templates for clusterclass machinepool
- Loading branch information
1 parent
e6610eb
commit b80750f
Showing
25 changed files
with
837 additions
and
26 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
9 changes: 9 additions & 0 deletions
9
templates/flavors/aks-clusterclass/azure-managed-cluster-template.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,9 @@ | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureManagedClusterTemplate | ||
metadata: | ||
name: ${CLUSTER_NAME} | ||
namespace: default | ||
spec: | ||
template: | ||
spec: {} | ||
|
15 changes: 15 additions & 0 deletions
15
templates/flavors/aks-clusterclass/azure-managed-controlplane-template.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,15 @@ | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureManagedControlPlaneTemplate | ||
metadata: | ||
name: ${CLUSTER_NAME}-control-plane | ||
namespace: default | ||
spec: | ||
template: | ||
spec: | ||
identityRef: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureClusterIdentity | ||
name: ${CLUSTER_IDENTITY_NAME} | ||
location: ${AZURE_LOCATION} | ||
subscriptionID: ${AZURE_SUBSCRIPTION_ID} | ||
version: ${KUBERNETES_VERSION} |
23 changes: 23 additions & 0 deletions
23
templates/flavors/aks-clusterclass/azure-managed-machinepool-template.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,23 @@ | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureManagedMachinePoolTemplate | ||
metadata: | ||
name: ${CLUSTER_NAME}-pool0 | ||
namespace: default | ||
spec: | ||
template: | ||
spec: | ||
mode: System | ||
name: pool0 | ||
sku: ${AZURE_NODE_MACHINE_TYPE} | ||
--- | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureManagedMachinePoolTemplate | ||
metadata: | ||
name: ${CLUSTER_NAME}-pool1 | ||
namespace: default | ||
spec: | ||
template: | ||
spec: | ||
mode: User | ||
name: pool1 | ||
sku: ${AZURE_NODE_MACHINE_TYPE} |
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,43 @@ | ||
apiVersion: cluster.x-k8s.io/v1beta1 | ||
kind: ClusterClass | ||
metadata: | ||
name: ${CLUSTER_CLASS_NAME} | ||
namespace: default | ||
spec: | ||
controlPlane: | ||
ref: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureManagedControlPlaneTemplate | ||
name: ${CLUSTER_NAME}-control-plane | ||
infrastructure: | ||
ref: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureManagedClusterTemplate | ||
name: ${CLUSTER_NAME} | ||
workers: | ||
machinePools: | ||
- class: default-system | ||
template: | ||
bootstrap: | ||
ref: | ||
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 | ||
kind: KubeadmConfigTemplate | ||
name: ${CLUSTER_NAME}-pool0 | ||
infrastructure: | ||
ref: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureManagedMachinePoolTemplate | ||
name: ${CLUSTER_NAME}-pool0 | ||
- class: default-worker | ||
template: | ||
bootstrap: | ||
ref: | ||
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 | ||
kind: KubeadmConfigTemplate | ||
name: ${CLUSTER_NAME}-pool1 | ||
infrastructure: | ||
ref: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureManagedMachinePoolTemplate | ||
name: ${CLUSTER_NAME}-pool1 | ||
|
47 changes: 47 additions & 0 deletions
47
templates/flavors/aks-clusterclass/kubeadm-config-template.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,47 @@ | ||
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 | ||
kind: KubeadmConfigTemplate | ||
metadata: | ||
name: ${CLUSTER_NAME}-pool0 | ||
namespace: default | ||
spec: | ||
template: | ||
spec: | ||
files: | ||
- contentFrom: | ||
secret: | ||
key: worker-node-azure.json | ||
name: replace_me | ||
owner: root:root | ||
path: /etc/kubernetes/azure.json | ||
permissions: "0644" | ||
joinConfiguration: | ||
nodeRegistration: | ||
kubeletExtraArgs: | ||
azure-container-registry-config: /etc/kubernetes/azure.json | ||
cloud-provider: external | ||
name: '{{ ds.meta_data["local_hostname"] }}' | ||
preKubeadmCommands: [] | ||
--- | ||
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 | ||
kind: KubeadmConfigTemplate | ||
metadata: | ||
name: ${CLUSTER_NAME}-pool1 | ||
namespace: default | ||
spec: | ||
template: | ||
spec: | ||
files: | ||
- contentFrom: | ||
secret: | ||
key: worker-node-azure.json | ||
name: replace_me | ||
owner: root:root | ||
path: /etc/kubernetes/azure.json | ||
permissions: "0644" | ||
joinConfiguration: | ||
nodeRegistration: | ||
kubeletExtraArgs: | ||
azure-container-registry-config: /etc/kubernetes/azure.json | ||
cloud-provider: external | ||
name: '{{ ds.meta_data["local_hostname"] }}' | ||
preKubeadmCommands: [] |
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,10 @@ | ||
apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
namespace: default | ||
resources: | ||
- clusterclass.yaml | ||
- azure-managed-controlplane-template.yaml | ||
- azure-managed-cluster-template.yaml | ||
- azure-managed-machinepool-template.yaml | ||
- ../../azure-cluster-identity | ||
- kubeadm-config-template.yaml |
9 changes: 9 additions & 0 deletions
9
templates/flavors/aks-clusterclass/patches/managedazurecluster-identity-ref.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,9 @@ | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureManagedControlPlaneTemplate | ||
metadata: | ||
name: ${CLUSTER_NAME}-control-plane | ||
spec: | ||
identityRef: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: AzureClusterIdentity | ||
name: "${CLUSTER_IDENTITY_NAME}" |
Oops, something went wrong.