Commit Graph

39 Commits

Author SHA1 Message Date
61bb408463 Merge pull request #18531 from coolljt0725/update_container_networking_on_create
fix docker inspect return unconsistent network settings  of created container and stopped container
Upstream-commit: 812a7c204a2396700ca1e95d949659b16302a120
Component: engine
2015-12-15 08:47:54 -08:00
19f8a4f8fb Merge pull request #18486 from aboch/vnd
Vendoring libnetwork bbd6e6d8ca1e7c9b42f6f53277b0bde72847ff90
Upstream-commit: 260cbb19c93ba1dc5aa0f4065cd5c95241bbd59d
Component: engine
2015-12-14 13:32:01 -08:00
3c4fcf6b7a Fix typos found across repository
Signed-off-by: Justas Brazauskas <brazauskasjustas@gmail.com>
Upstream-commit: 927b334ebfc786276a039e45ec097e71bf9a104c
Component: engine
2015-12-13 18:04:12 +02:00
941029f664 update network settings on container creating
To make docker inspect return a consistent result of networksettings
for created container and stopped container, it's bettew to update
the network settings on container creating.

Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: c427131c94369d5c49a4f14d78e6ab9c678e12df
Component: engine
2015-12-13 02:34:44 -05:00
3bcd3dfc58 Vendoring libnetwork bbd6e6d8ca1e7c9b42f6f53277b0bde72847ff90
Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: 8fe6b3835c87abf0c48d60f9c1f70bdcb496566c
Component: engine
2015-12-09 13:48:24 -08:00
cb6bc1b323 Implement all inspect commands with the new inspector interface.
It makes the behavior completely consistent across commands.
It adds tests to check that execution stops when an element is not
found.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 57b6796304880331d0d4e9cbefab7b139e718915
Component: engine
2015-12-09 12:05:01 -05:00
f437e2a3c8 Add format flag to network inspect
…for consistency as docker inspect and docker volume inspect supports it too

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 295c27388dd1e7cc4196fbb8ffe0646b33bacb5b
Component: engine
2015-12-02 22:32:10 +01:00
6e71f2c42e Merge pull request #17489 from WeiZhang555/network-rm-multi
Enhance `docker network rm` to delete multi net
Upstream-commit: a600bf4eab48a19ea9d1919f95f612cdb229c893
Component: engine
2015-11-23 08:25:33 +01:00
3a475c3707 Enhance docker network rm to delete multi net
This commit enhance `docker network rm` command to allow user to delete
multi networks at the same time.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: e7eb6687ef7da34cd69b27cfbaf3fd8112073530
Component: engine
2015-11-22 05:37:00 +08:00
7980b28dbf Replace s.d.Start() with s.d.StartWithBusybox()
Signed-off-by: Stefan Scherer <scherer_stefan@icloud.com>
Upstream-commit: aef344dcf801b1af67bc7ce6219e636e48c28a1f
Component: engine
2015-11-20 22:16:19 +01:00
3898bf4aaf Merge pull request #17615 from WeiZhang555/17404-net-inspect-name
Include container names in `network inspect`
Upstream-commit: a4acb1db4ae899e5b331b4b2724bda990e6f1371
Component: engine
2015-11-13 11:54:59 -08:00
24f23c55ef Test to verify --mac-address doesn't get applied to new endpoint
created on network connect.

Signed-off-by: Lei Jitang <leijitang@huawei.com>
Signed-off-by: Santhosh Manohar <santhosh@docker.com>
Upstream-commit: 451b79d69102ad95f1b91a52bb4b17c240f41e56
Component: engine
2015-11-06 14:52:35 -08:00
4955633439 Allow port mapping only for endpoint created on docker run
Signed-off-by: Santhosh Manohar <santhosh@docker.com>
Upstream-commit: dedcf6a6ff6d3aa75efaeb31c197b1c3a19305be
Component: engine
2015-11-06 13:54:17 -08:00
c27bddf6a0 Prevent connecting to host and prevent disconnecting from host
Container has private network namespace can not to connect to host
and container with host network can not be disconnected from host.

Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: a2d8c93fc690c2244a3bed32a2bbeb8dae449f90
Component: engine
2015-11-09 10:19:53 +08:00
8e86de45f2 Include container names in network inspect
This commit makes `docker network inspect` print container names as
service discovery is based on container name.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: fbed26297dca2adc59d891c661548302ec848984
Component: engine
2015-11-05 19:16:13 +08:00
3e428b6f0a Merge pull request #17637 from aaronlehmann/network-test-name-typo
Fix typo in name of integration test TestInspectApiMultipeNetworks
Upstream-commit: c90125dc8aef413a21792804748754abb2785229
Component: engine
2015-11-02 20:42:36 -05:00
8b4073166b Fix typo in name of integration test TestInspectApiMultipeNetworks
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 701e5dfe8aa4d3d964e375911a334674c5e5480a
Component: engine
2015-11-02 17:30:16 -08:00
51f09a359c IT for ungraceful daemon restart with multiple host-mode containers
Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: b323e3df8bcb52607e57d5f49dcb7a93edafa84a
Component: engine
2015-11-02 14:00:11 -08:00
e2a063d0d8 Fix bug in initializeNetwork()
- On `docker run --net <network id> ...`
  the bug would cause the container to attempt
  to connect to the network two times
- Also made sure endpoint creation rollback will
  be executed on failures in `func (container *Container) connectToNetwork()`

Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: 45e71a79840887b7974387bedba0544015ab4e3b
Component: engine
2015-11-02 11:20:15 -08:00
30dea50165 IT for daemon restarts when container connected to multiple networks
Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: e16e794805ec1e578951f271af7993d9619a4ede
Component: engine
2015-10-30 16:25:25 -07:00
057d34fa0f Fix network inspect for default networks.
- Keep old fields in NetworkSetting to respect the deprecation policy.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: f301c5765a0d7f4b6866cedfdface6f87874ff53
Component: engine
2015-10-30 16:55:21 -04:00
1384f6d7a7 Merge pull request #17518 from WeiZhang555/integration-test-bug
bug fix for test cases
Upstream-commit: 05534b6f8007e1f614cccdf9467e07a8cc38ae3d
Component: engine
2015-10-30 16:56:35 +01:00
f93a5200e3 bug fix for test cases
Fix bug that `isNwPresent` can't distinguish network names with same
prefix.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: 8f53edae3bd628e00f052182a3a5e84ee578f018
Component: engine
2015-10-30 15:13:35 +08:00
d7b7b49b51 Merge pull request #17499 from jfrazelle/fix-lxc-tests
lxc does not support exec
Upstream-commit: 2eaa25d3554dbe9f6d5c4f66a97c8eb83a463880
Component: engine
2015-10-29 15:08:13 -07:00
6cae6d09ea lxc does not support exec
Signed-off-by: Jessica Frazelle <acidburn@docker.com>
Upstream-commit: aaa134ea0e12781c7e1f19562544826274263a4b
Component: engine
2015-10-29 11:51:59 -07:00
a94cd37485 Execute buildPortMapInfo after Endpoint.Join()
- As the retrieved info may not be available at
  Endpoint creation time for certain network drivers
- Also retrieve the MAC address from Endpoint.Info().Iface()

Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: e03daebb48221bae84bfc48b0f9b652ced6d93f3
Component: engine
2015-10-29 11:47:30 -07: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
213dc33b1a Disable built-in SD on docker0 network
Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: be1c77595eed1d9b22511faf64783e4c65f40c61
Component: engine
2015-10-23 19:46:28 -07:00
95b57bebf2 Merge pull request #17274 from aboch/ai
Turn off discovery when icc == false
Upstream-commit: 2afdc6582b203c2beaeaca6ff14f61ae50f8cab9
Component: engine
2015-10-22 13:08:31 -07:00
553ed6afa5 Turn off service discovery when icc==false
- Turn off built-in service discovery on docker0 bridge
  when icc is false

Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: 20faaaa872444b6fffbc5a6d30310a782caafe0f
Component: engine
2015-10-22 12:02:02 -07:00
4a8a97b06e Merge pull request #17218 from vdemeester/17023-network-multiple-inspect
Add support for multiple network in inspect
Upstream-commit: 9f031f70ce832a5f3fde7bd902e66abeb44f19a9
Component: engine
2015-10-21 11:09:02 -07:00
9086b77304 Add support for multiple network in inspect
To be consistent with other inspect command (on container and images),
add the possiblity to pass multiple network to the network inspect
commands.

`docker network inspect host bridge none` is possible now.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 7af9f988ac535e4ae2e87976db25d4f7047274db
Component: engine
2015-10-21 08:57:29 +02:00
988eb3b3bf Do not mask ipam driver if no ip config is passed
Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: 27f908a051eb835c7cab59e596b8dee7ca92873b
Component: engine
2015-10-20 11:19:37 -07:00
08be0c3eb3 Pass network driver option in docker network command
Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: 6f3eb994b52dac9e336db9fe9f204e120553e8a7
Component: engine
2015-10-16 14:33:54 -07:00
9cdb750bf4 Merge pull request #17053 from liaoqingwei/dev2
use of checkers on docker_cli_network_unix_test.go
Upstream-commit: 835fbee9a23300569f95092c60fbc00eedddb6c5
Component: engine
2015-10-16 09:36:59 -04:00
2ebbc9e095 Use of checkers on docker_cli_network_unix_test.go.
Signed-off-by: liaoqingwei <liaoqingwei@huawei.com>
Upstream-commit: 9e3db08363fa85a08d7e6f9aa5059d19291c83c0
Component: engine
2015-10-16 16:56:40 +08:00
182a4806ba refactor use of container struct from daemon
- do existence check instead of get container
 - new connect method on daemon.
 - cli network disconnect integration test

Signed-off-by: Morgan Bauer <mbauer@us.ibm.com>
Upstream-commit: a0398fbd197b5c4cf261b702ba1a1f924d6134e8
Component: engine
2015-10-13 16:34:28 -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