]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commit
containers: use --cpus instead --cpu-quota
authorGuillaume Abrioux <gabrioux@redhat.com>
Fri, 10 Jan 2020 09:55:06 +0000 (10:55 +0100)
committerDimitri Savineau <savineau.dimitri@gmail.com>
Thu, 16 Jan 2020 18:51:43 +0000 (13:51 -0500)
commit3e262e072b0e86bbb431c47bc691bcad70783443
tree25001665e6397270993758ae8cf6318f93e38d11
parent8dcbcecd713b0cd7769d3b4d04ef5c2f15881377
containers: use --cpus instead --cpu-quota

When using docker 1.13.1, the current condition:

```
{% if (container_binary == 'docker' and ceph_docker_version.split('.')[0] is version_compare('13', '>=')) or container_binary == 'podman' -%}
```

is wrong because it compares the first digit (1) whereas it should
compare the second one.
It means we always use `--cpu-quota` although documentation recommend
using `--cpus` when docker version is 1.13.1 or higher.

From the doc:
> --cpu-quota=<value> Impose a CPU CFS quota on the container. The number of
> microseconds per --cpu-period that the container is limited to before
> throttled. As such acting as the effective ceiling.
> If you use Docker 1.13 or higher, use --cpus instead.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
infrastructure-playbooks/docker-to-podman.yml
roles/ceph-container-common/tasks/main.yml
roles/ceph-iscsi-gw/templates/rbd-target-api.service.j2
roles/ceph-iscsi-gw/templates/rbd-target-gw.service.j2
roles/ceph-iscsi-gw/templates/tcmu-runner.service.j2
roles/ceph-mds/templates/ceph-mds.service.j2
roles/ceph-mgr/templates/ceph-mgr.service.j2
roles/ceph-mon/templates/ceph-mon.service.j2
roles/ceph-osd/templates/ceph-osd-run.sh.j2
roles/ceph-rbd-mirror/templates/ceph-rbd-mirror.service.j2
roles/ceph-rgw/templates/ceph-radosgw.service.j2