Open jessehu opened 5 years ago
Can one of the admins verify this patch?
This will absolutely break my environment as is - 172.18.x.x is a valid internal IP set, not just used by docker. Please don't merge as is! :)
If you really do need to filter by IP, maybe add something to bootstrap options as a IP filter list, and then filter based on that - then at least it's something you have to specifically turn on, and you can choose your range.
Thanks @jjlimepoint. Your case "172.18.x.x" makes sense. "add something to bootstrap options as a IP filter list" is a good solution. I will update it later.
Hi @jjlimepoint , I have updated the patch to use bootstrap options for the IP filter. Please take a look.
When docker daemon runs in the VM, there will be a NIC created by Docker and usually has IP like 172.17.x.x. When VM is booting up, VM Tools sometimes reports this IP to vCenter, although the real IP of the non-docker nic will be reported later.
This patch can filter out the docker IP by specifying the prefix of the invalid machine IP via the bootstrap option 'invalid_ip_prefix'. e.g. invalid_ip_prefix: '172.17'.