1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00
Commit graph

15 commits

Author SHA1 Message Date
Jana Radhakrishnan
89045ca381 Modify driver Join api to only allow dst prefix
Currently the driver api allows the driver to specify the
full interface name for the interface inside the container.
This is not appropriate since the driver does not have the full
view of the sandbox to correcly allocate an unambiguous interface
name. Instead with this PR the driver will be allowed to specify
a prefix for the name and libnetwork and sandbox layers will
disambiguate it with an appropriate suffix.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-05-21 20:17:44 +00:00
Jana Radhakrishnan
8c5750558a Cleanup namespace files
It may happen that the application (docker) may exit ungracefully
exit without calling leaves on endpoint and may result in stale
namespace files. So if a sandbox is created with the same key
attempt to cleanup the file if it exists before creating the
sandbox.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-05-19 22:11:09 +00:00
Jana Radhakrishnan
030817808c Change default namespace path
Change namespace path to be /var/run/docker/netns since
/var/run/netns is being used by iproute2 and it is mounted
as MS_SHARED which causes some complications during integration.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-05-18 23:05:10 +00:00
Jana Radhakrishnan
7f7d9abd87 Make endpoint Join and Leave multi-thread safe
- Refactored the Join/Leave code so they are synchronized across multiple go-routines
    - Added parallel test coverage to test mult-thread access to Join/Leave
    - Updated sandbox code to revert back to caller namespace when removing interfaces
    - Changed the netns path to /var/run/netns so the cleanup is simpler on machine
      reboot scenario

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-05-10 17:36:04 +00:00
bin liu
e1003fb078 fix some typos
Signed-off-by: bin liu <liubin0329@gmail.com>
2015-05-07 09:22:06 +00:00
Jana Radhakrishnan
f055e06f3a Added RemoveInterface support to sandbox.
Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-05-06 00:34:38 +00:00
Jana Radhakrishnan
55099e9656 - Removed sandbox override option from the driver.
- Reworked the host network mode support by introducing
  a new JoinOption.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-05-05 04:26:23 +00:00
Jana Radhakrishnan
66eb3e1cd4 - Added support for JoinInfo so that driver can override certain
container config.
- Added JoinOption processing for extra /etc/hosts record.
- Added support for updating /etc/hosts entries of other containers.
- Added sandbox support for adding a sandbox without the OS level create.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-05-05 00:09:11 +00:00
Jana Radhakrishnan
b8f81862d0 - Added Join option support
- Added basic /etc/hosts generation support in libnetwork

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-04-30 05:58:12 +00:00
Jana Radhakrishnan
e2d8531a40 - Added support for Join/Leave methods to Endpoint.
- Removed sandbox key argument for CreateEndpoint.
- Refactored bridge driver code to remove sandbox key.
- Fixed bridge driver code for gaps in ipv6 behavior
  observed during docker integration.
- Updated test code, readme code, README.md according
  api change.
- Fixed some sandbox issues while testing docker ipv6
  integration.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-04-29 14:49:32 +00:00
Alessandro Boch
21ed154c79 Rename setGatewayIP() in sandbox pkg
- setGatewayIP() => programGateway() becsause it is
  causing confusion with setGateway() and setGatewayIPv6()

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-04-24 17:08:50 -07:00
Jana Radhakrishnan
c6fd92a565 - Fixed an assortment of bugs in sandbox
- Added more test coverage to sandbox

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-04-24 05:17:50 +00:00
Alessandro Boch
7d24e974cf Refactor driverapi, sandbox pkgs
- Move SanboxInfo and Interface structures in sandbox package
  (changed it to Info as per golint)
- Move UUID to new internal pkg types
- Updated .gitignore to ignore IDE project files

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-04-21 09:44:39 -07:00
Jana Radhakrishnan
0a25032277 Converted IP address and gateway values to be proper types
rather than strings in the sandbox and driverapi protocol

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-04-14 01:36:58 +00:00
Jana Radhakrishnan
68ae284db5 Libnetwork refactor for container network model
- Added controller, network, endpoint and sandbox interfaces
    - Created netutils package for miscallaneous network utilities
    - Created driverapi package to break cyclic dependency b/w driver and libnetwork
    - Made libnetwork multithread safe
    - Made bridge driver multithread safe
    - Fixed README.md

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-04-13 21:40:50 +00:00
Renamed from libnetwork/namespace.go (Browse further)