Commit graph

392 commits

Author SHA1 Message Date
Aleksa Sarai
4357ed4a73 *: purge dockerinit from source code
dockerinit has been around for a very long time. It was originally used
as a way for us to do configuration for LXC containers once the
container had started. LXC is no longer supported, and /.dockerinit has
been dead code for quite a while. This removes all code and references
in code to dockerinit.

Signed-off-by: Aleksa Sarai <asarai@suse.com>
2016-01-26 23:47:02 +11:00
Madhu Venugopal
e38463b277 Move port-mapping ownership closer to Sandbox (from Endpoint)
https://github.com/docker/libnetwork/pull/810 provides the more complete
solution for moving the Port-mapping ownership away from endpoint and
into Sandbox. But, this PR makes the best use of existing libnetwork
design and get a step closer to the gaol.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2016-01-26 03:59:03 -08:00
Alessandro Boch
733245b2e7 Save endpoint config only if endpoint creation succeeds
- Currently it is being save upfront...

Signed-off-by: Alessandro Boch <aboch@docker.com>
2016-01-25 13:43:32 -08:00
Santhosh Manohar
da9eadb066 IT for service/network name with '.', corrected libnetwork flag for DNS
Signed-off-by: Santhosh Manohar <santhosh@docker.com>
2016-01-21 20:49:02 -08:00
Brian Goff
9ae51b3e0f Merge pull request #19383 from calavera/container_store
Extract container store from the daemon.
2016-01-21 17:20:47 -05:00
David Calavera
3c82fad441 Extract container store from the daemon.
- Generalize in an interface.
- Stop abusing of List for everything.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2016-01-19 13:21:41 -05:00
Daniel Dao
84e14754e1 only close LogDriver after LogCopier is done
this prevents the copier from sending messages in the buffer to the closed
driver. If the copied took longer than the timeout to drain the buffer, this
aborts the copier read loop and return back so we can cleanup resources
properly.

Signed-off-by: Daniel Dao <dqminh@cloudflare.com>
2016-01-18 17:47:57 +00:00
Tibor Vass
9365b301a8 Merge pull request #19339 from cpuguy83/19335_revert_18736
Revert "Break big lock into some tiny locks"
2016-01-14 16:53:39 -05:00
David Calavera
73a5393bf3 Merge pull request #19242 from mavenugo/nsalias
Network scoped alias support
2016-01-14 10:58:51 -08:00
Brian Goff
f093e1273d Revert "Break big lock into some tiny locks"
This reverts commit 1326f0cba5.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2016-01-14 13:38:09 -05:00
Madhu Venugopal
dda513ef65 Network scoped alias support
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2016-01-14 08:44:41 -08:00
Wen Cheng Ma
9f676ade0a Add network ID to container inspect
Fixes issue #19089

Signed-off-by: Wen Cheng Ma <wenchma@cn.ibm.com>
2016-01-14 22:33:41 +08:00
Madhu Venugopal
e221b8a3d6 Support --link for user-defined networks
This brings in the container-local alias functionality for containers
connected to u ser-defined networks.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2016-01-12 13:38:48 -08:00
Tibor Vass
47074030f6 Merge pull request #19121 from WeiZhang555/tty-resize
Check nil Terminal to avoid panic
2016-01-11 11:29:15 -05:00
Sebastiaan van Stijn
967acd56c1 Merge pull request #18512 from euank/18510-fixOomKilled
Set OOMKilled state on any OOM event
2016-01-11 00:09:26 +01:00
Arnaud Porterie
fe3d1f9dd7 Merge pull request #19198 from sanimej/vin
Vendoring libnetwork
2016-01-10 11:46:34 -08:00
Sebastiaan van Stijn
a082f80832 Merge pull request #18736 from WeiZhang555/tiny-lock
Break big lock into some tiny locks for containerStart
2016-01-09 00:35:26 +01:00
Santhosh Manohar
64a6dc3558 Docker changes for libnetwork vendoring..
Signed-off-by: Santhosh Manohar <santhosh@docker.com>
2016-01-08 14:13:55 -08:00
Alessandro Boch
2bb3fc1bc5 Allow user to choose the IP address for the container
Signed-off-by: Alessandro Boch <aboch@docker.com>
2016-01-08 10:09:16 -08:00
Zhang Wei
7f0d304f37 Check nil Terminal to avoid panic
Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
2016-01-07 10:07:12 +08:00
David Calavera
907407d0b2 Modify import paths to point to the new engine-api package.
Signed-off-by: David Calavera <david.calavera@gmail.com>
2016-01-06 19:48:59 -05:00
David Calavera
723be0a332 Merge pull request #18888 from calavera/event_types
Event all the things!
2016-01-04 13:07:33 -08:00
Sebastiaan van Stijn
db738dd77f Merge pull request #15666 from vdemeester/3519-configurable-escape
Implement configurable escape key for attach/exec
2016-01-04 00:49:07 +01:00
Vincent Demeester
15aa2a663b Implement configurable detach key
Implement configurable detach keys (for `attach`, exec`, `run` and
`start`) using the client-side configuration

- Adds a `--detach-keys` flag to `attach`, `exec`, `run` and `start`
  commands.
- Adds a new configuration field (in `~/.docker/config.json`) to
  configure the default escape keys for docker client.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2016-01-03 23:03:39 +01:00
David Calavera
9d12d09300 Add volume events.
Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-12-30 17:39:33 -05:00
Lei Jitang
518ed75e1a Fix docker stats show wrong memory limit when do docker update
When a container create with -m 100m and then docker update other
cgroup settings such as --cpu-quota, the memory limit show by
docker stats will become the default value but not the 100m.

Signed-off-by: Lei Jitang <leijitang@huawei.com>
2015-12-29 20:33:16 -05:00
Qiang Huang
8799c4fc0f Implemet docker update command
It's used for updating properties of one or more containers, we only
support resource configs for now. It can be extended in the future.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2015-12-28 19:19:26 +08:00
Zhang Wei
1326f0cba5 Break big lock into some tiny locks
Don't involve code waiting for blocking channel in locked critical
section because it has potential risk of hanging forever.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
2015-12-23 13:23:23 +08:00
David Calavera
7ac4232e70 Move Config and HostConfig from runconfig to types/container.
- Make the API client library completely standalone.
- Move windows partition isolation detection to the client, so the
  driver doesn't use external types.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-12-22 13:34:30 -05:00
David Calavera
056e744903 Replace usage of pkg/nat with go-connections/nat.
Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-12-22 13:31:46 -05:00
David Calavera
4fef42ba20 Replace pkg/units with docker/go-units.
Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-12-16 12:26:49 -05:00
Euan
0b5131444d Set OOMKilled state on any OOM event
This restores the behavior that existed prior to #16235 for setting
OOMKilled, while retaining the additional benefits it introduced around
emitting the oom event.

This also adds a test for the most obvious OOM cases which would have
caught this regression.

Fixes #18510

Signed-off-by: Euan <euank@amazon.com>
2015-12-15 19:27:57 +00:00
Jess Frazelle
2180dd6cf0 Merge pull request #18617 from tiborvass/cleanup-builder
Cleanup builder: remove container package dependency
2015-12-15 09:59:29 -08:00
Brian Goff
ce0b1841c8 Merge pull request #17034 from rhvgoyal/volume-propagation
Capability to specify per volume mount propagation mode
2015-12-15 12:14:41 -05:00
Tibor Vass
c70f8b3c9c builder: remove container package dependency
Signed-off-by: Tibor Vass <tibor@docker.com>
2015-12-15 17:24:07 +01:00
Vivek Goyal
a2dc4f79f2 Add capability to specify mount propagation per volume
Allow passing mount propagation option shared, slave, or private as volume
property.

For example.
docker run -ti -v /root/mnt-source:/root/mnt-dest:slave fedora bash

Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
2015-12-14 10:39:53 -05:00
Justas Brazauskas
927b334ebf Fix typos found across repository
Signed-off-by: Justas Brazauskas <brazauskasjustas@gmail.com>
2015-12-13 18:04:12 +02:00
Qiang Huang
464eefd795 Add lock for container update
Container needs to be locked when updating the fields, and
this PR also remove the redundant `parseSecurityOpt` since
it'll be done in `setHostConfig`.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2015-12-11 10:33:13 +08:00
Daniel Nephin
efda9618db Move networking api types to the api/types/networking package.
Signed-off-by: Daniel Nephin <dnephin@gmail.com>
2015-12-09 13:55:59 -08:00
Jessica Frazelle
6707f4b9b6
inital seccomp support
Signed-off-by: Jessica Frazelle <acidburn@docker.com>
2015-12-03 16:30:44 -08:00
Tibor Vass
5bb4d0d9ea Move DisconnectFromNetwork back to daemon/
Signed-off-by: Tibor Vass <tibor@docker.com>
2015-12-03 20:10:27 +01:00
David Calavera
6bb0d1816a Move Container to its own package.
So other packages don't need to import the daemon package when they
want to use this struct.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Signed-off-by: Tibor Vass <tibor@docker.com>
2015-12-03 17:39:49 +01:00