
version: "3.9" services: redis: image: redis:alpine deploy: resources: limits: cpus: '0.50' memory: 50M reservations: cpus: '0.25' memory: 20M 1 privil 2023 年 3 月 22 日 docker-compose 这玩意怎么说呢,维护得比较差,很多参数可能坑比较大。 |
2 modrich 2023 年 3 月 22 日 2.启动 container 时加入--compatibility 参数 docker-compose --compatibility up -d 详见 https://www.jianshu.com/p/ba5518476057 |
3 是不是为了 Oracle 的实例 “保活” ? hh |
4 jenlors 2023 年 3 月 22 日 docker-compose 需要在 swarm 模式下才能限制 CPU 内存这些东西,单机模式是不支持的 |
5 SKYNE OP |
6 SKYNE OP 自己在更新 Docker-compose 至最新的 v2.17.0 版本后,运行官方示例,竟然可以了。。。\狗头 |
9 jenlors 2023 年 3 月 22 日 奇怪,可能是官方文档没及时更新吧,https://docs.docker.com/compose/compose-file/compose-file-v3/#deploy > sub-options only takes effect when deploying to a swarm with docker stack deploy, and is ignored by docker-compose up and docker-compose run, except for resources. |
10 jenlors 2023 年 3 月 22 日 修正,好像是说除了 resources 其它都不生效 |