Commit Graph

530 Commits

Author SHA1 Message Date
Jana Radhakrishnan 3527ebe475 Fix networking issues in RHEL/Centos 6.6
Some parts of the bridge driver code needs to use a different kernel
api or use the already existing apis in slightly different ways to
make the bridge driver work in RHEL/Centos 6.6. This PR provides
those fixes.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-07-02 09:31:13 -07:00
Jana Radhakrishnan ccc42943dd Use ioctls to create bridge
The netlink way of creating bridge has problems in older
kernels like the one used on RHEL 6 (which is a supported
one). So trying to use ioctl method to create bridge
so that it works on any version.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-07-02 09:27:53 -07:00
Jana Radhakrishnan 6e3e9644da Updated Godeps
Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-07-02 09:24:12 -07:00
aboch d1b8d48166 Merge pull request #356 from runseb/typo-overlay
small typo in the requirements
2015-07-01 10:06:28 -07:00
Sebastien Goasguen 956c4f8ef7 small typo in the requirements 2015-07-01 15:35:52 +02:00
Madhu Venugopal 3bf84c6c03 Merge pull request #270 from amylindburg/master
Update ROADMAP.md
2015-06-30 17:14:56 -07:00
Jana Radhakrishnan c59cd1298e Merge pull request #352 from mavenugo/master
Updating to latest netns to fix amd64 / RPI issues
2015-06-30 15:06:25 -07:00
Madhu Venugopal d0e3d0c3fb Updating to latest netns to fix amd64 / RPI issues
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-30 14:46:49 -07:00
Madhu Venugopal 4c14cd316f Merge pull request #348 from aboch/is
Endpoint interface stats read fails when invoked from docker
2015-06-30 11:04:39 -07:00
Alessandro Boch d01976c969 Endpoint interface stats read fails when invoked from docker
- When invoked from docker, endpoint.Statistics() returns
  the statistics of the host's interfaces.

  Issue is tracked down to ioutil.ReadFile(). For some
  reason even if invoked from inside the sandbox netns,
  it ends up reading the stats file from the default netns,
  when invoked from docker.
  If same operation is run from inside a dedicated binary,
  it works as expected.

- Replacing it with exec.Command("cat", <file>) solves the issue

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-29 20:29:41 -07:00
Madhu Venugopal 5c57ba5f54 Merge pull request #342 from alexwlchan/master
Minor spelling fixes in documentation and code comments
2015-06-29 19:57:09 -07:00
Madhu Venugopal 105a07f347 Merge pull request #346 from aboch/is
Endpoint to expose interfaces' statistics
2015-06-29 16:45:04 -07:00
Alessandro Boch 6b80e22053 Endpoint to expose interfaces' statistics
Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-29 16:15:31 -07:00
Madhu Venugopal d68e862b5e Merge pull request #345 from mbentley/overlay-doc-fix
Fixed URL used by curl in overlay readme
2015-06-26 21:26:58 -07:00
Matt Bentley a57a2af191 Fixed URL used by curl in overlay readme
Signed-off-by: Matt Bentley <mbentley@mbentley.net>
2015-06-26 21:07:26 -04:00
Jana Radhakrishnan f536e7c7aa Merge pull request #339 from nerdalert/overlay-doc
multi-host overlay driver quick start doc
2015-06-26 13:15:49 -07:00
Jana Radhakrishnan 01d9fc486d Merge pull request #335 from glevand/for-merge-netns
netns: Update to latest for arm64
2015-06-26 13:14:57 -07:00
Madhu Venugopal 64d1b728bb Merge pull request #278 from LK4D4/firewalld_support
Resurrect firewalld support
2015-06-26 13:12:19 -07:00
Alex Chan 86f32c245b Minor spelling fixes in documentation and code comments 2015-06-26 11:02:54 +01:00
Brent Salisbury 1dbc1bc4fe multi-host overlay driver quick start doc 2015-06-25 21:47:41 -07:00
aboch 7d501b2b73 Merge pull request #304 from wulonghui/wulonghui-patch-1
Update modprobe bridge output
2015-06-25 16:51:30 -07:00
aboch ece45cbf53 Merge pull request #333 from calavera/extra_conditional
Remove extra conditional.
2015-06-25 14:59:19 -07:00
Jana Radhakrishnan b3ea0cc828 Merge pull request #314 from spikecurtis/store-create-v2
Datastore handles creating objects atomically.
2015-06-25 14:43:16 -07:00
Geoff Levand f1bfee5048 netns: Update to latest for arm64
Signed-off-by: Geoff Levand <geoff@infradead.org>
2015-06-25 14:22:00 -07:00
Spike Curtis e2a63dff5a Datastore handles creating objects atomically.
In that commit, AtomicPutCreate takes previous = nil to Atomically create keys
that don't exist.  We need a create operation that is atomic to prevent races
between multiple libnetworks creating the same object.

Previously, we just created new KVs with an index of 0 and wrote them to the
datastore.  Consul accepts this behaviour and interprets index of 0 as
non-existing, but other data backends do no.

 - Add Exists() to the KV interface.  SetIndex() should also modify a KV so
   that it exists.
 - Call SetIndex() from within the GetObject() method on DataStore interface.
   - This ensures objects have the updated values for exists and index.
 - Add SetValue() to the KV interface.  This allows implementers to define
   their own method to marshall and unmarshall (as bitseq and allocator have).
 - Update existing users of the DataStore (endpoint, network, bitseq,
   allocator, ov_network) to new interfaces.
 - Fix UTs.
2015-06-25 10:53:48 -07:00
David Calavera 6885ea8036 Remove extra conditional.
Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-06-25 09:58:16 -07:00
Jana Radhakrishnan cc86aee642 Merge pull request #328 from wulonghui/wulonghui-patch-3
Update error return in bridge driver's getNetwork
2015-06-24 23:59:54 -07:00
wulonghui 7df8d3eb4c Update error return in bridge driver's getNetwork 2015-06-25 19:33:46 +08:00
Madhu Venugopal 82a1f56349 Merge pull request #330 from mrjana/sd
Do not update /etc/hosts for empty endpoints
2015-06-24 12:30:26 -07:00
Jana Radhakrishnan 6f65b9b17d Do not update /etc/hosts for empty endpoints
There is no need to update the /etc/hosts files
of containers for endpoints which are created/deleted
in a network whose interface list is empty

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-06-24 12:09:44 -07:00
Alexander Morozov 0220b06cd6 Resurrect firewalld support
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-06-21 16:42:01 -07:00
Madhu Venugopal 1aaf1047fd Merge pull request #326 from mavenugo/wneigh
Fixing a windows compile error in docker during vendor-in
2015-06-21 03:30:56 -07:00
Madhu Venugopal 7086aa85b1 Fixing a windows compile error in docker during vendor-in
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-21 02:32:07 -07:00
Jana Radhakrishnan 83743db8ce Merge pull request #325 from mavenugo/master
removed a duplicate and incorrect unlock
2015-06-20 08:44:19 -07:00
Madhu Venugopal 2ef8276789 removed a duplicate and incorrect unlock
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-20 08:22:44 -07:00
Madhu Venugopal 852a9c48c1 Merge pull request #324 from mrjana/cnm
Add LeaveAll support
2015-06-19 20:19:35 -07:00
Jana Radhakrishnan df92dd2b9a Add LeaveAll support
Currently container can join one endpoint when it is started.
More endpoints can be attached at a later point in time. But
when that happens this attachment should only have meaning
only as long as the container is alive. The attachment should
lose it's meaning when the container goes away. Cuurently there
is no way for the container management code to tell libnetwork
to detach the container from all attached endpoints. This PR
provides an additional API `LeaveAll` which adds this
functionality,

To facilitate this and make the sanbox lifecycle consistent
some slight changes have been made to the behavior of sandbox
management code. The sandbox is no longer destroyed when the
last endpoint is detached from the container. Instead the sandbox
ie kept alive and can only be destroyed with a `LeaveAll` call.
This gives better control of sandbox lifecycle by the container
management code and the sandbox doesn't get destroyed from under
the carpet while the container is still using it.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-06-19 18:55:26 -07:00
Jana Radhakrishnan 8f5549c695 Merge pull request #323 from mavenugo/master
leave must not use join options in the defer during failures
2015-06-19 15:06:13 -07:00
Madhu Venugopal b561d4c8c6 leave must not use join options in the defer during failures
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-19 14:48:07 -07:00
Jana Radhakrishnan 8feadc2dd9 Merge pull request #322 from mavenugo/master
Ignoring locally scoped endpoints/networks from distributed delete
2015-06-19 13:48:30 -07:00
Madhu Venugopal fe42c32355 Ignoring locally scoped endpoints/networks from distributed delete
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-19 13:34:16 -07:00
Jana Radhakrishnan 20c6d6904c Merge pull request #320 from mavenugo/master
set the kv-provider driver labels only if it is a valid config
2015-06-19 06:51:33 -07:00
Madhu Venugopal 3b9d45d214 set the kv-provider driver labels only if it is a valid config
without this fix, overlay driver returns an error and that causes the
daemon to quit.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-19 06:30:37 -07:00
Madhu Venugopal ceb30a05b9 Merge pull request #318 from mrjana/sd
Service discovery lite
2015-06-19 06:18:10 -07:00
Jana Radhakrishnan 0741d68fd7 Service discovery
Add a minimal service discover support using service names or
service names qualified with network name. This is achieved
by populating the container's /etc/hosts file record with the
appropriate entries

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-06-19 00:40:37 -07:00
Jana Radhakrishnan d59cc6962e Add/Delete etc hosts record support
Currently the etchosts package only provides helpers
to completely build an /etc/hosts file from scratch
or update a single hostname's IP address to a different
one. This commit adds the ability to add/delete an arbitrary
number of host record entries to/from the etc hosts file

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-06-19 00:40:27 -07:00
Jana Radhakrishnan afe092d5f3 Merge pull request #316 from mavenugo/epip
Fix endpoint ip data-store sync issue
2015-06-18 19:14:17 -07:00
Madhu Venugopal fb272a1f36 Fix endpoint ip data-store sync issue
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-18 19:07:00 -07:00
Madhu Venugopal 0e7322b485 Merge pull request #308 from mrjana/overlay
Overlay Driver
2015-06-18 16:08:26 -07:00
Jana Radhakrishnan a63a3e5463 Updated Godeps
Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
2015-06-18 15:07:22 -07:00