projectcalico / bird

Calico's fork of the BIRD protocol stack
91 stars 86 forks source link

Add dind (docker-in-docker) + bird container image #106

Closed coutinhop closed 1 year ago

coutinhop commented 1 year ago

Description

Add dind (docker-in-docker) + bird container image. This is needed to emulate external networks connected to external bird instances for node STs.

Todos

coutinhop commented 1 year ago

@coutinhop Thanks, the code change looks good to me. Can you provide more context about where this is going to be used?

Thank you, Nell!

Sure, context is: we'll use it to test a multiple external network with overlapping IP addresses scenario. Essentially, the way I've come up with is having docker-in-docker with an endpoint (say, an nginx server) in each bird instance which will represent an external network (before resorting to this, I did try having different networks on the "top-level" docker, but couldn't manage to have overlapping/same IP addresses in them). So by combining dind+bird, we could "emulate" this particular scenario for testing.

Please let me know if I couldn't make myself clear enough and I'll try to elaborate further...

nelljerram commented 1 year ago

Thanks Pedro - yes, I think that generally makes sense, and wish you luck with the details of setting it up. I was just reviewing how it compares with what we do in the node STs, which also use dind: https://github.com/projectcalico/calico/blob/master/node/tests/st/utils/docker_host.py#L114. But perhaps the key difference is that you are interested in modelling external BIRD nodes outside the cluster, whereas the node ST is using DIND to model the cluster nodes?

coutinhop commented 1 year ago

Thanks Pedro - yes, I think that generally makes sense, and wish you luck with the details of setting it up. I was just reviewing how it compares with what we do in the node STs, which also use dind: https://github.com/projectcalico/calico/blob/master/node/tests/st/utils/docker_host.py#L114. But perhaps the key difference is that you are interested in modelling external BIRD nodes outside the cluster, whereas the node ST is using DIND to model the cluster nodes?

Yes, precisely, these are to model the BGP peers from outside the cluster. Though I hadn't seen this calico/dind image before, perhaps I could have done things differently than what I did (not sure if worth it to spend that time now though).

Thanks once again!