Configure the Docker daemon
For more details on available configuration options, please refer to dockerd
documentation.
Mandatory options
The following are the mandatory options to ensure the Docker daemon runs in the kube-nodes.
{
"bridge": "none",
"iptables": false,
"ip-masq": false,
"storage-driver": "overlay2",
"storage-opts": [ "overlay2.override_kernel_check=true" ]
},
"registry-mirrors": ["https://local-registry.example.com"]
}
Configuring
To enable custom dockerd
configuration perform the following steps:
- Create a new file, for example
daemon.json
, that enables Docker daemon debug logging:
{
"bridge": "none",
"iptables": false,
"ip-masq": false,
"storage-driver": "overlay2",
"storage-opts": [ "overlay2.override_kernel_check=true" ],
"debug": true
}
- Create a DC/OS secret with the configuration file.
$ dcos security secrets create -f daemon.json kubernetes-cluster/dockerd-config
- To enable custom Docker configuration you need to set
.kubernetes.docker_daemon_config
with the name of the DC/OS secret where the configuration is stored.
{
"kubernetes": {
"docker_daemon_config": "kubernetes-cluster/dockerd-config"
}
}