Commit Graph

23 Commits

Author SHA1 Message Date
44cb4a4db6 api,daemon: cleanup some unused stuff
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: ed5d335e22143b35f928e5a8740b046c21db808b
Component: engine
2016-06-21 14:15:19 -07:00
be63983b3a Add Swarm management backend
As described in our ROADMAP.md, introduce new Swarm management API
endpoints relying on swarmkit to deploy services. It currently vendors
docker/engine-api changes.

This PR is fully backward compatible (joining a Swarm is an optional
feature of the Engine, and existing commands are not impacted).

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Signed-off-by: Victor Vieux <vieux@docker.com>
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: 534a90a99367af6f6bba1ddcc7eb07506e41f774
Component: engine
2016-06-13 22:16:18 -07:00
6e410ce449 Add "driver" filter for network ls
This add a new filter to 'docker network ls'
to allow filtering by driver-name.

Contrary to "ID" and "name" filters, this
filter only supports an *exact* match.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 23e418b6c966a43a463a064053ce0c741b8e5159
Component: engine
2016-04-29 16:22:26 +02:00
1beaa5c119 Add network label filter support
This patch did following:

1) Make filter check logic same as `docker ps ` filters

Right now docker container logic work as following:
when same filter used like below:
 -f name=jack -f name=tom
it would get all containers name is jack or tom(it is or logic)

when different filter used like below:

 -f name=jack -f id=7d1
it would get all containers name is jack and id contains 7d1(it is and logic)

It would make sense in many user cases, but it did lack of compliate filter cases,
like "I want to get containers name is jack or id=7d1", it could work around use
(get id=7d1 containers' name and get name=jack containers, and then construct the
final containers, they could be done in user side use shell or rest API)

2) Fix one network filter bug which could include duplicate result
when use -f name=  -f id=, it would get duplicate results

3) Make id filter same as container id filter, which means match any string.
not use prefix match.

It is for consistent match logic

Closes: #21417

Signed-off-by: Kai Qiang Wu(Kennan) <wkqwu@cn.ibm.com>
Upstream-commit: f812b55692f5d50d427684216ad6c806bac5a702
Component: engine
2016-04-18 00:38:48 +00:00
56103ffaad Remove runconfig package dependency from image and container routers.
Use an interface to specify the behavior of a configuration decoder.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: f0d26e1665f7552972db5b041554cc7b45bc3060
Component: engine
2016-03-28 16:23:51 -04:00
91e6a2df59 Remove runconfig dependency from network routes.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 3ca29823d42ab1e2b1ea76981ccc9aa11e858cb2
Component: engine
2016-03-28 16:23:50 -04:00
4ec2693c9e Modify import paths to point to the new engine-api package.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 907407d0b2e5863f0e1b40b93a356bbf03c7b9fb
Component: engine
2016-01-06 19:48:59 -05:00
b006691148 Replace usage of pkg/nat with go-connections/nat.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 056e7449039af522fa0a1567ef67916eaa0de93e
Component: engine
2015-12-22 13:31:46 -05:00
1c526ceb5c Move networking api types to the api/types/networking package.
Signed-off-by: Daniel Nephin <dnephin@gmail.com>
Upstream-commit: efda9618db07152ce6a94e0ac391ba58d1463fcd
Component: engine
2015-12-09 13:55:59 -08:00
4bf986fcb9 Modify IPAMConfig structure json tags
- So that it complies with docker convention for inspect

Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: d795bc7d53db4b9e9194d0570d65e22d39f58384
Component: engine
2015-10-30 12:57:49 -07:00
6c30abdc61 Extract network settings types for inspect.
Keeping backwards compatibility.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Signed-off-by: Tibor Vass <tibor@docker.com>
Upstream-commit: 25682577c9d29b325b4b615c4b88c132a4640082
Component: engine
2015-10-27 19:16:21 -04:00
c2f87fdd0e Fix docker inspect container only reports last assigned information
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 1b9a08e719776e53b7aea1a89c2c29fbf27b1ae4
Component: engine
2015-10-27 16:26:06 -04:00
3ad728d9e8 Do not update etc/hosts for every container
- Only user named containers will be published into
  other containers' etc/hosts file.
- Also block linking to containers which are not
  connected to the default network

Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: 4f6f00e1916a8c58e67c8118d015988d86718d19
Component: engine
2015-10-26 20:08:57 -07:00
7a285e518e IPAM API & UX
introduced --subnet, --ip-range and --gateway options in docker network
command. Also, user can allocate driver specific ip-address if any using
the --aux-address option.
Supports multiple subnets per network and also sharing ip range
across networks if the network-driver and ipam-driver supports it.
Example, Bridge driver doesnt support sharing same ip range across
networks.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: cc6aece1fdefbc10638fe9e462a15608c6093115
Component: engine
2015-10-13 11:03:03 -07:00
8623fdfb48 Network remote APIs using new router, --net=<user-defined-network> changes
* Moving Network Remote APIs out of experimental
* --net can now accept user created networks using network drivers/plugins
* Removed the experimental services concept and --default-network option
* Neccessary backend changes to accomodate multiple networks per container
* Integration Tests

Signed-off-by: David Calavera <david.calavera@gmail.com>
Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: 2ab94e11a2a8499088a72ab27fd09e897d8c810a
Component: engine
2015-10-07 03:54:19 -07:00
357660a251 Docker changes for libnetwork Sandbox
- Ground-work for integrating with user namespace support

Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: 56fdb05258d1ab2153fec268ed22cf9d1227c356
Component: engine
2015-09-02 17:24:56 -07:00
262b85d1ce Remove PortMapping from container NetworkSettings
Signed-off-by: Antonio Murdaca <runcom@linux.com>
Upstream-commit: db4f20404d2b8c4da5a15e447f52cd634445cfe3
Component: engine
2015-09-02 14:32:53 +02:00
3c87acb006 Windows: Enable NAT port mapping
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 4393be71005e63ab305f4d87481dbd23b7594d18
Component: engine
2015-08-12 13:17:27 -07:00
b04bea4cce golint on daemon/network package
Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: 7be8336fb54ae2907c8f6549f26272c102a867af
Component: engine
2015-07-21 22:49:49 +08:00
9161e24479 Move /nat to /pkg/nat
By convention /pkg is safe to use from outside the docker tree, for example
if you're building a docker orchestrator.

/nat currently doesn't have any dependencies outside of /pkg, so it seems
reasonable to move it there.

This rename was performed with:

```
gomvpkg -vcs_mv_cmd="git mv {{.Src}} {{.Dst}}" \
	-from github.com/docker/docker/nat \
        -to   github.com/docker/docker/pkg/nat

```

Signed-off-by: Peter Waller <p@pwaller.net>
Upstream-commit: 9c2374d19623581028f070bc93fa4c60a660dce4
Component: engine
2015-06-30 17:43:17 +01:00
13426de5e6 Docker integration with libnetwork
- Updated Dockerfile to satisfy libnetwork GOPATH requirements.
    - Reworked daemon to allocate network resources using libnetwork.
    - Reworked remove link code to also update network resources in libnetwork.
    - Adjusted the exec driver command population to reflect libnetwork design.
    - Adjusted the exec driver create command steps.
    - Updated a few test cases to reflect the change in design.
    - Removed the dns setup code from docker as resolv.conf is entirely managed
      in libnetwork.
    - Integrated with lxc exec driver.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
Upstream-commit: d18919e304c240df84502cdcc5ed655d92d12d4f
Component: engine
2015-05-19 22:40:19 +00:00
d7e8665b03 Add --userland-proxy daemon flag
The `--userland-proxy` daemon flag makes it possible to rely on hairpin
NAT and additional iptables routes instead of userland proxy for port
publishing and inter-container communication.

Usage of the userland proxy remains the default as hairpin NAT is
unsupported by older kernels.

Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
Upstream-commit: f42348e18f73d1d775d77ac75bc96466aae56d7c
Component: engine
2015-05-04 16:07:45 -07:00
0c091d906f Remove jobs from daemon/networkdriver/bridge
Signed-off-by: Tibor Vass <tibor@docker.com>
Upstream-commit: 53582321ee502335a9c3be4789bef984e09f77c4
Component: engine
2015-04-08 18:50:29 -04:00