worstcase / blockade

Docker-based utility for testing network failures and partitions in distributed applications

Home Page:http://blockade.readthedocs.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Is it possible to assign static IP address to the containers?

mminisha opened this issue · comments

Like in docker-compose is it possible to assign static IP address in blockade? Looks like, blockade is assigning IP address at later stage in the lifecycle of containers (not sure), when I use

docker run --net mynet123 --ip 20.21.10.100 -it c197324bf9c3 -p 52204:52204
docker run -p 52205:52205 --net mynet123 --ip 20.21.10.101 -it c197324bf9c3

The nodes form a cluster as I expected. With blockade the application is not starting up.

In my case, I have to give the IP address of docker in the config file of my application when building an image itself.

This is not supported directly. However as I answered in your other question, you could use blockade add to add containers you've launched elsewhere.