Skip to content

Commit

Permalink
Improve maas cluster template (#79)
Browse files Browse the repository at this point in the history
* update default machine configuration for maas template

* optional resource pool configuration for control plane and worker machines
  • Loading branch information
neoaggelos authored Sep 12, 2023
1 parent 7d684df commit 1f5c1fb
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
12 changes: 8 additions & 4 deletions templates/cluster-template-maas.rc
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,14 @@ export MAAS_DNS_DOMAIN="maas"

# Control plane machine configuration
export CONTROL_PLANE_MACHINE_MINCPU="1"
export CONTROL_PLANE_MACHINE_MINMEMORY="2"
export CONTROL_PLANE_MACHINE_IMAGE="ubuntu"
export CONTROL_PLANE_MACHINE_MINMEMORY="2048"
export CONTROL_PLANE_MACHINE_IMAGE="u-2204-k-1261-0"

# Worker machine configuration
export WORKER_MACHINE_MINCPU="1"
export WORKER_MACHINE_MINMEMORY="2"
export WORKER_MACHINE_IMAGE="ubuntu"
export WORKER_MACHINE_MINMEMORY="2048"
export WORKER_MACHINE_IMAGE="u-2204-k-1261-0"

# (optional) Configure resource pools for control plane and worker machines
# export CONTROL_PLANE_MACHINE_RESOURCEPOOL="kvm-pool"
# export WORKER_MACHINE_RESOURCEPOOL="bare-metal-pool"
2 changes: 2 additions & 0 deletions templates/cluster-template-maas.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ spec:
minCPU: ${CONTROL_PLANE_MACHINE_MINCPU}
minMemory: ${CONTROL_PLANE_MACHINE_MINMEMORY}
image: ${CONTROL_PLANE_MACHINE_IMAGE}
resourcePool: ${CONTROL_PLANE_MACHINE_RESOURCEPOOL:= }
---
apiVersion: cluster.x-k8s.io/v1beta1
kind: MachineDeployment
Expand Down Expand Up @@ -87,6 +88,7 @@ spec:
minCPU: ${WORKER_MACHINE_MINCPU}
minMemory: ${WORKER_MACHINE_MINMEMORY}
image: ${WORKER_MACHINE_IMAGE}
resourcePool: ${WORKER_MACHINE_RESOURCEPOOL:= }
---
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1
kind: MicroK8sConfigTemplate
Expand Down

0 comments on commit 1f5c1fb

Please sign in to comment.