Skip to content

Kubernetes mutator webhook for setting Pod node selector.

Notifications You must be signed in to change notification settings

skpr/k8s-mutate-nodeselector

Repository files navigation

Kubernetes Mutator Webhook: NodeSelector

A solution for locking Pods which reside in a specific namespace to a sepcific node group.

Why

We are waiting for EKS to ship support for scheduler.alpha.kubernetes.io/node-selector.

apiVersion: v1
kind: Namespace
metadata:
 name: your-namespace
 annotations:
   scheduler.alpha.kubernetes.io/node-selector: env=test

Link to the issue can be found here:

aws/containers-roadmap#304

Usage

apiVersion: v1
kind: Namespace
metadata:
 name: your-namespace
 annotations:
   k8s-mutate-nodeselector.skpr.io/namespace: env=test