worstcase / blockade

Docker-based utility for testing network failures and partitions in distributed applications
http://blockade.readthedocs.org
Apache License 2.0
907 stars 72 forks source link

Allow publish without expose, use non-deprecated api, state docker version requirement #15

Closed aidanhs closed 9 years ago

aidanhs commented 9 years ago

These are a bunch of misc fixes which are useful independent of any native execution driver.

I believe this PR will fix #12 - at some point after 1.4, Docker started requiring you expose a port if you want to publish it.

There's one commit in here ("Expose must be a list as of 1.7.0") which is a bit odd given my discovery that 1.6.2 is the max version of docker available with the LXC driver - this is in preparation for native driver support.

NOTE BREAKING CHANGE: I have swapped the order of port publishing to be {external: internal} (like fig and the docker command line) - the Docker api accepts it as {internal: external}, so it now has to be swapped round. Apparently even the blockade documentation was confused about this! http://blockade.readthedocs.org/en/latest/config.html

labisso commented 9 years ago

thanks much! I'll get a release out soon. I'm also really hoping to get the native driver working sometime. I have a proof of concept that works, and that would simplify a ton of things.

aidanhs commented 9 years ago

I too have a POC which uses nsenter - if you have a better way then that's good.

As of Docker 1.8 the lxc driver is deprecated.