Change the IP range used by Docker
This page indicates how to change the IP ranges used by Docker.
By default, docker will use these two ranges:
172.17.0.0/16: for thebridgenetwork (also calleddocker0)172.18.0.0/16: for thedocker_gwbridgenetwork
If the procedure is followed during the installation of Cyberwatch, only steps 3 and 4 are necessary.
Stop the instance:
sudo cyberwatch stopDisconnect and remove network
docker_gwbridgedocker network disconnect -f docker_gwbridge gateway_ingress-sbox docker network rm docker_gwbridgeEdit file
/etc/docker/daemon.json:{ "bip": "10.0.64.1/24", "default-address-pools": [ { "base": "10.0.64.0/18", "size": 24 } ] }The field
bip(Bridge IP) defines the IP range that network interfacedocker0can use. The example reserves IP range10.0.64.1/24to the interface. Beware, the range must end with.1, otherwise docker won’t start.The field
default-address-poolsdefines the IP range of network interfacedocker_gwbridge. The example reserves IP range10.0.64.0/18.Restart docker:
sudo systemctl restart dockerStart Cyberwatch:
sudo cyberwatch startCheck that the IPs changed:
docker network inspect bridge | grep Subnet docker network inspect docker_gwbridge | grep Subnet