I have two containers withing my pod (PodA)
The first container (C1) has the following limits
Limits:
cpu: 2
memory: 1Gi Requests:
cpu: 100m
memory: 128Mi
The second container (C2) has no requests/limits specified
I have the following questions
- From what I can see with a
kubectl describe nodes, the memory/cpu request/limits for thePodAare the same as the one fromC1. Is that correct? - What are the memory/cpu limits for
C2? Is it unbounded? Limited to the limits ofPodA(e.g. limits ofC1)? - Follow up of #2 -> What happens if
C2asks for more than 1Gi of memory? Will the container run out of memory, and cause the whole pod to crash? Or will it be able to grab more memory, as long as the node has free memory?
I tried to google, but all the examples I saw where some where resource limits are set for both of the containers
spec:template, if you want to have a specific value for the container then specify the value under containers, else the pod will inherit the value from thespec:template