jpetazzo / pipework

Software-Defined Networking tools for LXC (LinuX Containers)
Apache License 2.0
4.21k stars 727 forks source link

Adding metadata to openvswitch database. #212

Closed oldgregg closed 7 years ago

oldgregg commented 7 years ago

Pipework doesn't populate the openvswitch database with any information about the pipework interface creation. This makes it difficult to glean any information about the container to which an interface is assigned.

This patch adds the bridge, interface name, container ID and vlan to the database so other tools can query it.

This patch was originally designed to help tools like @dreamcat4's docker-pipework image clean up these interfaces when the container is started with something like 'docker run --rm' (with modifications).

jpetazzo commented 7 years ago

Thanks! That seems like an excellent idea. I don't have an OVS setup here to test it, so I'm merging it blindly (I trust you! :)) since it seems to only affect openvswtich setups anyway.

Thanks again!