concepts/configuration/manage-compute-resources-container.md: fix a conversion (#4952)

Rewrite the description for spec.containers[].resources.limits.cpu
pull/4344/merge
Radhika Puthiyetath 2017-09-05 15:28:36 -07:00 committed by Zach Corleissen
parent 8d79723fe6
commit e0517e0799
1 changed files with 6 additions and 9 deletions

View File

@ -135,14 +135,12 @@ When using Docker:
[`--cpu-shares`](https://docs.docker.com/engine/reference/run/#/cpu-share-constraint)
flag in the `docker run` command.
- The `spec.containers[].resources.limits.cpu` is converted to its millicore value,
multiplied by 100000, and then divided by 1000. This number is used as the value
of the [`--cpu-quota`](https://docs.docker.com/engine/reference/run/#/cpu-quota-constraint)
flag in the `docker run` command. The [`--cpu-period`] flag is set to 100000,
which represents the default 100ms period for measuring quota usage. The
kubelet enforces cpu limits if it is started with the
[`--cpu-cfs-quota`] flag set to true. As of Kubernetes version 1.2, this flag
defaults to true.
- The `spec.containers[].resources.limits.cpu` is converted to its millicore value and
multiplied by 100. The resulting value is the total amount of CPU time that a container can use
every 100ms. A container cannot use more than its share of CPU time during this interval.
**Note**: The default quota period is 100ms. The minimum resolution of CPU quota is 1ms.
{: .note}
- The `spec.containers[].resources.limits.memory` is converted to an integer, and
used as the value of the
@ -434,4 +432,3 @@ consistency across providers and platforms.
{% endcapture %}
{% include templates/concept.md %}