#120: extend not add

This commit is contained in:
Muayyad alsadi 2021-06-22 23:52:24 +03:00
parent 5ed5528294
commit f417c9ab8c

View File

@ -531,13 +531,13 @@ def container_to_res_args(cnt, podman_args):
# add args # add args
cpus = cpus_limit_v3 or cpus_limit_v2 cpus = cpus_limit_v3 or cpus_limit_v2
if cpus: if cpus:
podman_args.add('--cpus', str(cpus)) podman_args.extend(('--cpus', str(cpus),))
mem = mem_limit_v3 or mem_limit_v2 mem = mem_limit_v3 or mem_limit_v2
if mem: if mem:
podman_args.add('-m', str(mem).lower()) podman_args.extend(('-m', str(mem).lower(),))
mem_res = mem_res_v3 or mem_res_v2 mem_res = mem_res_v3 or mem_res_v2
if mem_res: if mem_res:
podman_args.add('--memory-reservation', str(mem_res).lower()) podman_args.extend(('--memory-reservation', str(mem_res).lower(),))
def container_to_args(compose, cnt, detached=True): def container_to_args(compose, cnt, detached=True):
# TODO: double check -e , --add-host, -v, --read-only # TODO: double check -e , --add-host, -v, --read-only