<p>We are trying to create namespace with specific node pool. How to achieve that on Azure Kubernetes?</p>
<pre><code>error: Unable to create namespace with specific node pool.
Ex: namespace for user nodepool1
</code></pre>

<p>Posting this as a community wiki, feel free to edit and expend it.</p>
<p>As <a href="https://stackoverflow.com/users/5951680/luca-ghersi">Luca Ghersi</a> mentioned in comments, it's possible to have namespaces assigned to a specific nodes. For this matter there's an admission controller <code>PodNodeSelector</code> (you can read about it on <a href="https://kubernetes.io/docs/reference/access-authn-authz/admission-controllers/#podnodeselector" rel="nofollow noreferrer">kubernetes official documentation</a>).</p>
<p>In short words:</p>
<blockquote>
<p>This admission controller defaults and limits what node selectors may
be used within a namespace by reading a namespace annotation and a
global configuration.</p>
</blockquote>
<p>Based on <a href="https://learn.microsoft.com/en-us/azure/aks/faq#what-kubernetes-admission-controllers-does-aks-support-can-admission-controllers-be-added-or-removed" rel="nofollow noreferrer">Azure FAQ</a>, Azure AKS has this admission controller enabled by default.</p>
<pre><code>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.
</code></pre>
