10up / wp-local-docker-v2

ARCHIVED: A simple Docker based development environment for WordPress.
MIT License
484 stars 81 forks source link

The use of ip gateway 10.0.0.1 causing conflicts with provider gateways #175

Open grahammtbr opened 3 years ago

grahammtbr commented 3 years ago

Describe the bug Maybe not a bug per say, but I spent hours this past weekend banging my head against my desk and swearing at my internet provider when I couldn't access any of my development sites. Turns out I learnt the hard way that not all routers use 192.168.x.x for local IP addresses, and 10updocker has hardcoded the docker gateway as 10.0.0.1. After shutting down docker entirely I was finally able to access the gateways settings and change my IP gateway to 10.1.1.1, but this is likely going to cause issues when I work elsewhere where I don't have the luxury of changing the local IP, as all gateways provided by Shaw Communications (largest internet provider in Western Canada) in the last year use the 10.0.0.1 gateway. The equipment they're using is the Comcast xFi Gateways, which also use 10.0.0.1, so it's not just a local issue.

Steps to Reproduce Set your router's IP gateway to 10.0.0.1, and try to run a .test 10updocker based site.

Additional context I'm not an networking expert by any means, but in my forced crash course this weekend I've learnt that 10.0.0.1 is becoming common in residential routers, and is common in business networking. Would it not make more sense to use the 172.16.x.x range, as that doesn't seem to be used in off the shelf networking equipment?

I like what you guys have done with 10updocker, it allowed me to get started with zero knowledge of Docker/Docker-compose, but this is may end up being an issue for me going forward, and I'm guessing others as well.

web-apply commented 3 years ago

You can replace the 10.0.0.1 ip address with an alternative dhcp server ip. these can be for example 192.168.0.1 or 192.168.1.1. More information about 10.0.0.0.1 ip address can be found here: https://19216811.how/10.0.0.1/.

ahathaway commented 2 years ago

I am not sure what this comment from @web-apply is talking about but that doesn't really apply in this context. I am also having a similar issue. Basically the default xfinity lan settings place the router/modem @ 10.0.0.1 as to many other providers. I'm not at all sure why the 10up team went with the choice of 10.0.0.0/16 as the CIDR but being unable to set it to something else has been a real pain in the rear.