gpt4 book ai didi

docker - docker 无法识别默认地址池

转载 作者:IT老高 更新时间:2023-10-28 21:42:30 25 4
gpt4 key购买 nike

我正在尝试将 docker-compose 配置为默认使用不同的网络范围,所以我按照 https://github.com/moby/moby/pull/29376 中的说明进行操作

但是,我收到以下错误:

unable to configure the Docker docker daemon with file/etc/docker/daemon.json: the following directives don't match anyconfiguration option: default-address-pools

这是 daemon.json 的内容 - 它是从 #29376 中提取的样本。

{
"default-address-pools": [
{
"scope": "local",
"base": "172.80.0.0/16",
"size": 24
},
{
"scope": "global",
"base": "172.90.0.0/16",
"size": 24
}
]
}

请指教。

我的环境:

# uname -a
Linux gfn-classroom 4.4.0-109-generic #132-Ubuntu SMP Tue Jan 9 19:52:39 UTC
2018 x86_64 x86_64 x86_64 GNU/Linux

# docker --version
Docker version 17.12.0-ce, build c97c6d6

lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.3 LTS
Release: 16.04
Codename: xenial

最佳答案

这被合并到 https://github.com/moby/moby/pull/36396并且(希望)将在 18.06 中提供。 [ Reference ]

另请注意,更改默认地址池也可作为 cli 参数使用,例如:

/usr/bin/dockerd -H ... --default-address-pool base=172.29.0.0,size=16

关于docker - docker 无法识别默认地址池,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48279424/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com