feat: 解决容器编辑内存限额失败的问题 (#2607)

Refs #2608
This commit is contained in:
ssongliu
2023-10-22 08:43:27 +08:00
committed by wanghe-fit2cloud
parent 609aa04aba
commit a2bfa5acaa
+1
View File
@@ -885,6 +885,7 @@ func loadConfigInfo(isCreate bool, req dto.ContainerOperate, oldContainer *types
}
hostConf.NanoCPUs = int64(req.NanoCPUs * 1000000000)
hostConf.Memory = int64(req.Memory * 1024 * 1024)
hostConf.MemorySwap = 0
hostConf.PortBindings = portMap
hostConf.Binds = []string{}
config.Volumes = make(map[string]struct{})