如何在运行时更改分配给容器的资源? [英] How to change the resources allocated to a container at run time?

查看:48
本文介绍了如何在运行时更改分配给容器的资源?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道我可以在使用 -c -m CPU和内存的标志。

I am aware that I can limit the resources allocated to a container while provisioning using docker with the -c and -m flags for CPU and memory.

但是,有没有一种方法可以动态地将这些分配的资源更改为容器(在配置它们之后),而无需重新部署

However, is there a way I can change these allocated resources to containers dynamically (after they have been provisioned) and without redeploying the same container with changed resources?

推荐答案

目前不行-希望有人通过它实现该操作: https://github.com/docker/docker/issues/6323

not at present no - There is a desire to see someone implement it though: https://github.com/docker/docker/issues/6323

这篇关于如何在运行时更改分配给容器的资源?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆