Rename veth plugin to ptp and add docs.

ptp (point-to-point) better describes the nature of the plugin
as veth pairs are also used by the bridge plugin.
This commit is contained in:
Eugene Yakubovich 2015-07-10 12:18:25 -07:00
parent 58f6bc9c8b
commit f741bc324b

28
ptp.md Normal file
View File

@ -0,0 +1,28 @@
# ptp plugin
## Overview
The ptp plugin creates a point-to-point link between a container and the host by using a veth device.
One end of the veth pair is placed inside a container and the other end resides on the host.
Both ends receive an IP address out of a /31 range.
The IP of the host end becomes the gateway address inside the container.
Because ptp plugin requires a pair of IP addresses for each container, it should be used in conjuction with host-local-ptp IPAM plugin.
## Example network configuration
```
{
"name": "mynet",
"type": "ptp",
"ipam": {
"type": "host-local-ptp",
"subnet": "10.1.1.0/24"
}
}
## Network configuration reference
* `name` (string, required): the name of the network
* `type` (string, required): "ptp"
* `ipMasq` (boolean, optional): set up IP Masquerade on the host for traffic originating from this network and destined outside of it. Defaults to false.
* `mtu` (integer, optional): explicitly set MTU to the specified value. Defaults to value chosen by the kernel.
* `ipam` (dictionary, required): IPAM configuration to be used for this network.