We have a docker swarm setup with ingress and an application overlay network created. These networks are both /24. From these networks IP’s are assigned to the containers and also VIP to the swarm services, hence there’s a scarcity of IP’s available in these networks, due to which new service creations are sometimes failing. As a workaround, we removed some unwanted services, and scaled down certain services to make room for new services.
We need both ingress and app network to be of /16 range so as to support more IP’s. I’m ok to delete the existing swarm services, delete these ingress and app network, recreate them with /16 block and redeploy all 120+ services using CICD pipeline. Docker documentation says that the overlay networks should be of /24 blocks. In our use case we cannot break the network into multiple smaller chunks for various dependency reasons (deployments, CICD variables, task groups etc). so there are 2 concerns that I wanted to check.
- is it okay to create ingress network and application overlay network with /16 block as it contradicts with the docker documentation mentioned above? The documentation also conflicts with another documentation on customizing ingress network, where the example commands use a /16 block. I think the limitations are applicable when docker services are huge like 500 or 600+… but just thought of confirming this.
- apart from recreating the networks with /16 blocks, is there anything else that’s supposed to be done. I mean, any change to docker_gwbridge or anything else like that?