Commit Graph

472 Commits

Author SHA1 Message Date
Jana Radhakrishnan e88263dbf2 Merge pull request #309 from aboch/bis
Fix datastore value handling in bitseq
2015-06-18 12:17:01 -07:00
Alessandro Boch 0fd6fe8d28 Fix datastore value handling in bitseq
- and do not discard errors

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-18 12:07:04 -07:00
aboch 51baf26458 Merge pull request #307 from mavenugo/delp
Distributed delete processing
2015-06-17 17:42:16 -07:00
Jana Radhakrishnan ce01ecbef9 Merge pull request #290 from aboch/ia
ipam and idm for multi host
2015-06-17 17:27:12 -07:00
Alessandro Boch 9e9c43e948 Add datastore to IPAM for configuration
- IPAM to use datastore for the subnets configurations

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 17:17:19 -07:00
Madhu Venugopal 288e689b51 Distributed delete processing
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-17 17:11:20 -07:00
Alessandro Boch bca6ec2e64 Rework push reservation w/ datastore
- At Handle creation, first check if an instance of the
  the respective object is already present in the datastore.
- Handle sequence must be saved only if commit
  to datastore is succesfull
- Caller (ipam) needs to manage the retry

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:49:21 -07:00
Alessandro Boch 0020b76d39 Change subnet key schema in ipam
- to addrSpace/subnet/childSubnet

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:49:21 -07:00
Madhu Venugopal c87a2f4567 Datastore additions to bitmask management
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-17 16:49:19 -07:00
Madhu Venugopal 9f69b0aa0d Added a new RetryError to indicate the caller to possibly retry
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-17 16:46:08 -07:00
Alessandro Boch 62b7668b58 Make bitseq.Handle thread-safe
Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:46:08 -07:00
Alessandro Boch b512536cb3 Add numerical ids manager
Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:46:05 -07:00
Alessandro Boch eb66d4456e bitseq to provide handle
- Handle contains sequence and identifier.
  This way datastore integration can be done
  at bitseq level.

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:37:59 -07:00
Alessandro Boch f01ec8c471 Reorganize libnetwork ipam datastructures
- In order to facilitate usage of datastore
- This makes it slower. Efficiency will be
  revisited later after datastore integration
  is done.

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:37:59 -07:00
Alessandro Boch 0a4887a1ba Add locking to libnetwork ipam
Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:37:59 -07:00
Alessandro Boch 2c26fdf8df Add serialize/deserialize for sequence list
Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:37:59 -07:00
Alessandro Boch f80cf7ff08 Add libnetwork ipam implementation
Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:37:59 -07:00
Alessandro Boch 421edc42b3 Add ipam contract
Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:37:59 -07:00
Alessandro Boch c603907331 Add bitseq package
- Initial version
- It allows handling reservation/release of a finite set
  of resources through large bitmask.
- It represents the bitmask as a list of equal
  consecutive 32 bits long bitmask symbols.
  It basically operates on a run-length encoding
  of the bitmask without encode/decode processing.

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-17 16:37:59 -07:00
Madhu Venugopal 279ffaeeaa Merge pull request #299 from icecrime/13956_duplicate_iptables_rules
Fix duplicated iptables rules
2015-06-16 11:21:10 -07:00
Madhu Venugopal 3299e6b7d4 Fixed the tests.
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-16 10:46:51 -07:00
Arnaud Porterie 905f0eba77 Fix duplicated iptables rules
The `iptables.Exists` function is wrong in two ways:
1. The iptables -C call doesn't add `-j DOCKER` and fails to match
2. The long path takes ordering into account in comparison and fails to match

This patch fixes issue 1 by including `-j DOCKER` in the check.

Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
2015-06-16 10:46:47 -07:00
Jana Radhakrishnan 863fee7c2d Merge pull request #301 from mavenugo/master
Cleaning up iptables nat table on driver bootup
2015-06-16 09:35:13 -07:00
Madhu Venugopal 198ac62aef Cleaning up iptables nat table on driver bootup
This is required to have consistent behaviour as in 1.6.2.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-16 09:26:23 -07:00
aboch fc7abaa93f Merge pull request #298 from mavenugo/master
Fixed a basic UI regression due to a recent godep update
2015-06-16 01:07:04 -07:00
Madhu Venugopal 95d176a241 Fixed a basic UI regression due to a recent godep update
In one of the latest docker UI updates, the flags structure expects to
have a ShortUsage function. Without that any UI event that triggers an
short usage panics.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-15 20:19:29 -07:00
aboch 393d82832f Merge pull request #297 from mavenugo/chdr
Updating CallFunc to match the Docker CLI API changes
2015-06-15 09:51:07 -07:00
Madhu Venugopal 3c58b7a79d Updating CallFunc to match the Docker CLI API changes
Updated Docker deps to pickup UI changes

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-15 09:41:28 -07:00
Madhu Venugopal 41ce4e0280 Merge pull request #296 from aboch/dn
Add implementation for lookupContainerID
2015-06-15 03:49:41 -07:00
Alessandro Boch 1f8e86f1ba Add implementation for lookupContainerID
Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-15 02:45:30 -07:00
aboch 7af4d0b5c5 Merge pull request #295 from mavenugo/mapi
workaround to a minor bug in mux which filters out empty query
2015-06-15 01:35:39 -07:00
Madhu Venugopal 9b39726c0c workaround to a minor bug in mux which filters out empty query
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-15 01:25:45 -07:00
Jana Radhakrishnan 6ddf500c32 Merge pull request #294 from mavenugo/sdcli
Few changes to the UI and API implementation
2015-06-14 22:26:56 -07:00
Madhu Venugopal 5fcef105bb Few changes to the UI and API implementation
1. replaced --net option for service UI with SERVICE.[NETWORK] format
2. Making using of the default network/driver backend support
3. NetworkName and NetworkType from the UI/API can be empty string
   and it will be replaced with DefaultNetwork and DefaultDriver

As per the design goals, we wanted to keep libnetwork core free of
handling defaults. Rather, the clients (docker & dnet) must handle the
defaultness of these entities.
Also, since there is no API to get these Default values from the
backend, UI will not handle the default values either. Hence, this falls
under the responsibility of the API layer to handle this specific case.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-14 21:57:18 -07:00
Jana Radhakrishnan 18165e3c22 Merge pull request #293 from mavenugo/dlabels
support for daemon labels
2015-06-14 09:19:49 -07:00
Madhu Venugopal 0a49ceb0d0 support for libnetwork daemon labels
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-14 09:03:42 -07:00
Jana Radhakrishnan 281c387e46 Merge pull request #291 from mavenugo/master
Return an empty config if nil
2015-06-13 15:14:49 -07:00
Madhu Venugopal 580fd18ef3 Return an empty config if nil
Since the Config is a read-only entity, Confg() method returned a value
instead of the pointer. In cases the config is nil, we should return an
empty config.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-13 14:28:56 -07:00
Madhu Venugopal 3be488927d Merge pull request #277 from Microsoft/10662-compile3
Windows: Fix compile after SB interface
2015-06-12 12:58:37 -07:00
Jana Radhakrishnan 0f7399a4cb Merge pull request #289 from mavenugo/defcfg
Moved the TOML based Configuration to dnet
2015-06-12 12:58:06 -07:00
Madhu Venugopal f8eb4da90c Moved the TOML based Configuration to dnet
The configuration format for docker runtime is based on daemon flags and
hence adjusting the libnetwork configuration to accomodate it by moving
the TOML based configuration to the dnet tool.

Also changed the controller configuration via options

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-12 12:46:12 -07:00
John Howard 72b3215a20 Windows: Compiles again
Signed-off-by: John Howard <jhoward@microsoft.com>
2015-06-12 12:40:36 -07:00
aboch e03f32d73f Merge pull request #286 from mavenugo/master
Cherry-picked : enable hairpin mode on the bridge port & fix iptables rule
2015-06-12 08:39:00 -07:00
Madhu Venugopal 092460013c Merge pull request #284 from aboch/sv
Remove dnet binary
2015-06-11 19:32:32 -07:00
Madhu Venugopal acfac0ba4c enable hairpin mode on the bridge port & fix iptables rule
* When userland-proxy is disabled, enable hairpin mode on the host-side of the veth
* When userland-proxy is enabled, fix the iptable rules appropriately

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-11 19:23:02 -07:00
Alessandro Boch 5774cc2463 Remove dnet binary
- It slipped in as part of a previous commit by mistake

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-11 18:38:03 -07:00
Madhu Venugopal cd54fb3dbe Merge pull request #271 from aboch/sv
Rework service UI
2015-06-11 17:02:04 -07:00
Jana Radhakrishnan 137ca9700b Merge pull request #280 from mavenugo/libkv_m
Replace swarm store with libkv
2015-06-11 16:51:32 -07:00
Madhu Venugopal b714b04cac Replace swarm store with libkv
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-06-11 16:19:28 -07:00
Alessandro Boch 6f496671d8 Promote Service cli
- To the same level of Network cli
  and to make use of the new service
  rest apis

Signed-off-by: Alessandro Boch <aboch@docker.com>
2015-06-11 16:07:09 -07:00