Pod scalling to different node pool

Hello!

I am in the early stages of learning about Kubernetes and I have cluster deployed on Azure.
I have a couple of node pools configured slightly differently to give me optimized cost.

For my pod, I would like to configure a min number of replicas (ie: 2) and they should be running on a particular node pool and anything autoscaled thereafter I would like to run on a different node pool.

I am trying to understand if this is possible and how I can describe it into my YML file.

Appreciate if someone can suggest something around this!

Cluster information:

Kubernetes version: v1.23.15
Cloud being used: Azure
Installation method: AKS
Host OS: Linux

create an deployment yaml file and mention node selector parameter in that yaml

Hi Teja,

Thank you kindly for the reply. Doesn’t the node selector apply to all pods?
I just want the scaled pods to go to a particular node pool.

ie:
min number = 2 [userpool1 (label:foo)]
max number = 10 [pods 3 to 10 to run on userpool2 (label:bar)]

Appreciate the help!
GJ