2

We are trying to create namespace with specific node pool. How to achieve that on Azure Kubernetes?

error: Unable to create namespace with specific node pool.
Ex: namespace for user nodepool1
Wytrzymały Wiktor
  • 11,492
  • 5
  • 29
  • 37
satish p
  • 23
  • 1
  • 4
  • Does this answer your question? [How to assign a namespace to certain nodes?](https://stackoverflow.com/questions/52487333/how-to-assign-a-namespace-to-certain-nodes) – Luca Ghersi May 20 '21 at 12:29

1 Answers1

3

Posting this as a community wiki, feel free to edit and expend it.

As Luca Ghersi mentioned in comments, it's possible to have namespaces assigned to a specific nodes. For this matter there's an admission controller PodNodeSelector (you can read about it on kubernetes official documentation).

In short words:

This admission controller defaults and limits what node selectors may be used within a namespace by reading a namespace annotation and a global configuration.

Based on Azure FAQ, Azure AKS has this admission controller enabled by default.

AKS supports the following admission controllers:

- NamespaceLifecycle
- LimitRanger
- ServiceAccount
- DefaultStorageClass
- DefaultTolerationSeconds
- MutatingAdmissionWebhook
- ValidatingAdmissionWebhook
- ResourceQuota
- PodNodeSelector
- PodTolerationRestriction
- ExtendedResourceToleration

Currently, you can't modify the list of admission controllers in AKS.
moonkotte
  • 3,661
  • 2
  • 10
  • 25