title: Kubernetes "nice" a pod's CPU usage
body: <p>I have a cluster w/ 3 nodes.  Hurray!  The cluster doesn't autoscale nodes.</p>
  
  <p>These nodes run an amazing web app, yet most of the time do almost nothing.</p>
  
  <p>I also have a background process that could use an infinite amount of CPU (the usefulness drops rapidly but remains useful).</p>
  
  <p>I want these background pods to run on each Node and slowed down to leave a 20% CPU headroom on the Node.  Or similar.</p>
  
  <p>That's the shape of a DaemonSet.</p>
  
  <ul>
  <li><p>Can I tell Kubernetes to deprioritize the DaemonSet Pods w/ a 20% headroom? </p></li>
  <li><p>Can the DaemonSet Pods detect the Nodes CPU usage and deprioritize themselves (risky if buggy)?</p></li>
  </ul>
  
  <p><a href="https://kubernetes.io/docs/tasks/configure-pod-container/quality-service-pod/" rel="nofollow noreferrer">QoS</a> looks like it's for scheduling and evicting pods to make room for other pods, but they don't get 'niced'.</p>
  
  <p><a href="https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/" rel="nofollow noreferrer">Priority</a> also looks like it's for eviction.</p>