Juan
Juan

Reputation: 2103

Max pods per node

Dear members of stackoverflow,

It is possible to configure the maximum number of pods per node in the yaml configuration file of a kubernetes deployment? For example something as

---
kind: Deployment
apiVersion: extensions/v1beta1
metadata:
  name: cdn-akamai-pipe
spec:
  template:
    metadata:
      labels:
        app: cdn-akamai-pipe
    max-pods-per-node: 10 

Thanks

Upvotes: 1

Views: 927

Answers (2)

P Ekambaram
P Ekambaram

Reputation: 17689

Maximum number of pods should be set on Kubelet and not in deployment yaml

--max-pods int32

Number of Pods that can run on this Kubelet. (default 110)

Upvotes: 0

Spazzy757
Spazzy757

Reputation: 929

This is a kubelet setting that can be set using the --max-pods flag, https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet/#kubelet as such there is no way to set this using yaml configuration. If you are using a managed service this can generally be set during cluster creation

Upvotes: 2

Related Questions