Skip to content

assemblyline/k8s-node-labeler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Assemblyline

K8s node labeler

A small container that applies a label(s) to the k8s node it is running on.

e.g.

apiVersion: v1
kind: Pod
metadata:
  name: k8s-node-labeler
  namespace: kube-system
spec:
  hostNework: true
  restartPolicy: OnFailure
  containers:
    - name: apply-labels
      image: quay.io/assemblyline/k8s-node-labeler:0.0.1
      env:
        - name: POD_NAME
          valueFrom:
            fieldRef:
              fieldPath: metadata.name
        - name: LABELS
          value: '{ "disk": "ssd" }'
      volumeMounts:
        - mountPath: /etc/kubernetes/ssl
          name: kubernetes-ssl
          readOnly: true
  volumes:
    - name: kubernetes-ssl
      hostPath:
        path: /etc/kubernetes/ssl

Credit

Inspiration from: eliaslevy/docker-aws-node-labels

About

Adds labels to k8s nodes

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages