Commit Graph

7110 Commits

Author SHA1 Message Date
0595bffeac Update imports to be consistent
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 40c6d00c97c737d9d3827f159518007803affcc7
Component: engine
2014-04-01 07:07:42 +00:00
3edb80395b Ensure secound part of the key is provided
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 7a7f59210d5eb7a38a5fac8889010bd54576ea01
Component: engine
2014-03-31 23:12:08 +00:00
97a3970ba7 Update native driver to use labels from opts
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 6c9a47f01c583e9c22b831eb426192148d29d792
Component: engine
2014-03-27 09:04:54 +00:00
60570ca0ef Update lxc to use opts for selinux labels
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: bfa2141765c2a3866ca0f5237fc951f4c2db8b98
Component: engine
2014-03-27 08:57:01 +00:00
5ed6e1adb8 Fix compile and unit test errors after merge
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 2d270c4f06dbc2ee1293e3f81f6922df248ef8eb
Component: engine
2014-03-27 08:25:01 +00:00
f4111a1ccb Merge branch 'master' into pluginflag
Conflicts:
	pkg/cgroups/cgroups.go
	pkg/libcontainer/nsinit/exec.go
	pkg/libcontainer/nsinit/init.go
	pkg/libcontainer/nsinit/mount.go
	runconfig/hostconfig.go
	runconfig/parse.go
	runtime/execdriver/driver.go
	runtime/execdriver/lxc/lxc_template.go
	runtime/execdriver/lxc/lxc_template_unit_test.go
	runtime/execdriver/native/default_template.go
	runtime/execdriver/native/driver.go

Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: eab56ac007b263708b5526609c8be2bc19881467
Component: engine
2014-03-27 08:00:18 +00:00
8972e580e1 Merge pull request #4759 from crosbymichael/comments-in-buildfile
Strip comments before parsing line continuations
Upstream-commit: 5b9c8607d90c20282eb65b75112f09634bcba277
Component: engine
2014-03-28 11:16:32 +02:00
1861c25cbb Merge pull request #4880 from tianon/ignore-down-interfaces
Adjust TestOnlyLoopbackExistsWhenUsingDisableNetworkOption to ignore "DOWN" interfaces
Upstream-commit: 10b7ae39b95d3b4455616e35b407895ebdd55e06
Component: engine
2014-03-28 10:54:11 +02:00
1e8741dfed Merge pull request #4889 from crosbymichael/fix-commit-validation
Fix commit and import when no repository is specified
Upstream-commit: 0fb8146afa6001da0673f4178d73a6545aaa8ad2
Component: engine
2014-03-28 10:25:21 +02:00
ae0da14a77 Merge pull request #4442 from ibuildthecloud/hairpin-nat
Support hairpin NAT without going through docker server
Upstream-commit: d2327006d659595e88da653e054f826401b05727
Component: engine
2014-03-27 18:09:42 -07:00
da6de365f6 Merge pull request #4450 from alexlarsson/cgroups-systemd
Add systemd implementation of cgroups
Upstream-commit: 69ba31e17ea4dab6b040478720955dece5986f6c
Component: engine
2014-03-28 03:05:02 +02:00
85082e995b Merge pull request #4873 from crosbymichael/add-internal-symlinks
Follow symlinks inside container root for build's ADD
Upstream-commit: 45b43d85ecbffb7aa626c47ef086f09463d8f8f6
Component: engine
2014-03-27 15:46:48 -07:00
528335a67b Merge pull request #4871 from crosbymichael/bip-exists
Return error when existing bridge does not match ip
Upstream-commit: d848e2d113a6978a42cd5bb93fe57f9ea653b627
Component: engine
2014-03-27 14:51:21 -07:00
5f846085d9 cgroups: Add systemd implementation of cgroups
This implements cgroup.Apply() using the systemd apis.
We create a transient unit called "docker-$id.scope" that contains
the container processes. We also have a way to set unit specific
properties, currently only defining the Slice to put the
scope in.

Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com> (github: alexlarsson)
Upstream-commit: 6c7835050e53b733181ddfca6152c358fd625400
Component: engine
2014-03-27 22:44:31 +01:00
a2c3f01761 Add systemd.SdBooted()
This is a conversion of sd_booted() from libsystemd to go and checks
if the system was booted with systemd.

Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com> (github: alexlarsson)
Upstream-commit: 1296d5ce9ad43d8d833f6e5661da45aef6d4c26b
Component: engine
2014-03-27 22:44:31 +01:00
931e59cc5b pkg/systemd: Drop our copy-pasted version of go-systemd/activation
Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com> (github: alexlarsson)
Upstream-commit: cb43fd007133fc05b6bb2b0d3d58fef8b1e60537
Component: engine
2014-03-27 22:44:31 +01:00
4b9413542a Vendor github.com/godbus/dbus and github.com/coreos/go-systemd
We need this to do systemd API calls.

We also add the static_build tag to make godbus not use
os/user which is problematic for static builds.

Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com> (github: alexlarsson)
Upstream-commit: d4725801b3401d04b3f35b5783bdc0fc362f7f00
Component: engine
2014-03-27 22:44:26 +01:00
cf568a7031 cgroups: Join groups by writing to cgroups.procs, not tasks
cgroups.procs moves all the threads of the process, and "tasks" just
the one thread. I believe there is a risk that we move the main thread,
but then we accidentally fork off one of the other threads if the go
scheduler randomly switched to another thread. So, it seems safer (and
more correct) to use cgroups.procs.

Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com> (github: alexlarsson)
Upstream-commit: 9294d7f2af6ecb7c18be11fb5043fad4a61d8f09
Component: engine
2014-03-27 21:47:47 +01:00
4a0326289d cgroups: Splity out Apply/Cleanup to separate file/interface
This leaves only the generic cgroup helper functions in cgroups.go and
will allow easy implementations of other cgroup managers.

This also wires up the call to Cleanup the cgroup which was missing
before.

Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com> (github: alexlarsson)
Upstream-commit: 7f7d8419a71d49b25e4d38196b36e93b568bb61d
Component: engine
2014-03-27 21:47:47 +01:00
9e1caa6b4a Add --opt arguments for drivers
In order to handle special configuration for different drivers we
make the Config field a map to string array. This lets
us use it for lxc, by using the "lxc" key for those, and we can
later extend it easily for other backend-specific options.

Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com> (github: alexlarsson)
Upstream-commit: 7a3070a6000963d12be9dcd2698d911b848a33b6
Component: engine
2014-03-27 21:47:47 +01:00
13e17899e1 Merge pull request #4613 from tianon/add-cgroupfs-mention-to-packagers
Add mention of mounting cgroupfs properly to PACKAGERS.md
Upstream-commit: be5c65c2a2df00df806c497cf9d5d70c635eb38f
Component: engine
2014-03-27 13:26:31 -06:00
6c925a0b3c Merge pull request #4865 from creack/fix_fish_completion
Fix fish completion when having alias on awk or grep
Upstream-commit: 94538fe022b8f905e2cc6a132242375f7f120fb5
Component: engine
2014-03-27 13:07:11 -06:00
f731a44bb1 Merge pull request #4818 from viirya/fix_working_dir_not_dir
fix the problem when setting existing file as working dir
Upstream-commit: ba9f9b3c9268a1b201bcb10045da77b135d869d1
Component: engine
2014-03-27 11:41:18 -07:00
fac202530a Merge pull request #4879 from gorsuch/exec-upstart
Use "exec" in the upstart script to let upstart manage the docker process instead of a shell
Upstream-commit: db20cb0e1ac877ca3b51c66d179185f55e5b899b
Component: engine
2014-03-27 12:15:30 -06:00
e14a0de6e1 Merge pull request #4838 from crosbymichael/btrfs-ftw
Promote btrfs
Upstream-commit: 303a954151f89dc7d2c485417fd0a9bacabe9ad0
Component: engine
2014-03-27 19:55:25 +02:00
45a3d3da44 upstart: use exec here so upstart can monitor the process and not just a shell
Docker-DCO-1.1-Signed-off-by: Michael Gorsuch <michael.gorsuch@gmail.com> (github: gorsuch)
Upstream-commit: 73ee4879afd557a3ddd0740b0a281024060f2436
Component: engine
2014-03-27 12:44:33 -05:00
ad6fffc689 Adjust TestOnlyLoopbackExistsWhenUsingDisableNetworkOption to ignore "DOWN" interfaces
This fixes the following, which I've been seeing on all my machines for as long as I can remember:

--- FAIL: TestOnlyLoopbackExistsWhenUsingDisableNetworkOption (0.36 seconds)
	container_test.go:1597: Wrong interface count in test container: expected [*: lo], got [1: lo 2: sit0]

Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
Upstream-commit: ad3e71d5c7e01dca229d4077cf8b019d8085c33a
Component: engine
2014-03-27 11:06:32 -06:00
ef8b9a6c77 Merge pull request #4211 from rhatdan/master
Add SELinux support
Upstream-commit: 79e8ef28e43817e14d3df0779711fc4ca00b36d1
Component: engine
2014-03-27 10:26:05 -06:00
1a3ed0cbeb Fix commit and import when no repository is specified
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 097aef2ca938012a5b42e0032b30267e27a92265
Component: engine
2014-03-27 04:24:31 +00:00
6fd95365ed Strip comments before parsing line continuations
Fixes #3898
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 67af7b3fb0b5e40a435b434c57291cb2989275ce
Component: engine
2014-03-27 02:41:08 +00:00
1c550a00a4 Follow symlinks inside container root for build's ADD
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 0fb01fd8fe376a3518b1050ab62f2b3370d62535
Component: engine
2014-03-27 02:07:35 +00:00
f757666ccd This patch adds SELinux labeling support.
docker will run the process(es) within the container with an SELinux label and will label
all of  the content within the container with mount label.  Any temporary file systems
created within the container need to be mounted with the same mount label.

The user can override the process label by specifying

-Z With a string of space separated options.

-Z "user=unconfined_u role=unconfined_r type=unconfined_t level=s0"

Would cause the process label to run with unconfined_u:unconfined_r:unconfined_t:s0"

By default the processes will run execute within the container as svirt_lxc_net_t.
All of the content in the container as svirt_sandbox_file_t.

The process mcs level is based of the PID of the docker process that is creating the container.

If you run the container in --priv mode, the labeling will be disabled.

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
Upstream-commit: 4c4356692580afb3971094e322aea64abe0e2500
Component: engine
2014-03-26 15:30:40 -04:00
aa3273eb2a Merge pull request #4855 from unclejack/update_release_v0.9.1
Update master for release 0.9.1
Upstream-commit: ab00619c56738c0704374c68fb43f4dd90b8887e
Component: engine
2014-03-26 11:43:13 -07:00
70613c0a32 Fix fish completion when having alias on awk or grep
Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume@charmes.net> (github: creack)
Upstream-commit: e7f3234c1e4926c966f4c9e4cf08d9aae60d21bb
Component: engine
2014-03-26 09:05:21 -07:00
7c744319b0 Return error when existing bridge does not match ip
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: baba9cde9542b480162d11bd30ca3a522fa6b4d0
Component: engine
2014-03-26 11:51:27 +00:00
40b880e003 Change version to 0.9.1-dev
Docker-DCO-1.1-Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com> (github: unclejack)
Upstream-commit: b2721e05ce4d6026855718ad9b01eb7dec797cd2
Component: engine
2014-03-26 00:18:45 +02:00
a34af92d8d Bump to version v0.9.1
Docker-DCO-1.1-Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com> (github: unclejack)

Conflicts:
	VERSION
Upstream-commit: d36176652ef8f0220a1cff5dc00933400c69a562
Component: engine
2014-03-26 00:18:19 +02:00
365103a8e5 Merge pull request #4840 from vbatts/vbatts-load_from_input
docker load: add --input flag
Upstream-commit: 5506e4b62dfad9d79fbeed91b9696fb51c736631
Component: engine
2014-03-25 14:37:27 -07:00
da42bdb7df Merge pull request #4628 from kippandrew/port-allocator
Fix port collision with dynamically allocated ports
Upstream-commit: abef5cb0fcd107c751b7390bc7eb45e3ecd675e6
Component: engine
2014-03-25 14:30:10 -07:00
e9aaf94539 Merge pull request #4794 from alexlarsson/dm-better-shutdown
devicemapper: Better/faster shutdown
Upstream-commit: 6643cc20fe16f36ffb3342bec61a3c0f24d2a9df
Component: engine
2014-03-25 14:03:00 -07:00
d977af9bd0 Merge pull request #4842 from pda/installer-devicemapper-comment
Update AUFS comment in install.sh
Upstream-commit: e99297e4ebb716b37197f0f72bf35ad59399f669
Component: engine
2014-03-25 14:29:46 -06:00
6acb821d1b install.sh (get.docker.io) aufs comment updated.
devicemapper has landed, but the TODO hasn't been actioned presumably
because aufs is still preferred over devicemapper when available[1].

Comment updated accordingly.

Citation [1]: 267ca39921/runtime/graphdriver/driver.go (L40-L46)

Docker-DCO-1.1-Signed-off-by: Paul Annesley <paul@annesley.cc> (github: pda)
Upstream-commit: 576278102e0fa9166711f8cf23ec972fcccc085e
Component: engine
2014-03-25 11:33:16 -07:00
70fdc926f2 docker load: added example of a multiple tag image
Docker-DCO-1.1-Signed-off-by: Vincent Batts <vbatts@redhat.com> (github: vbatts)
Upstream-commit: 2517370088ad11765f99d75c16b58e93fe18f85a
Component: engine
2014-03-25 08:30:59 -04:00
674da9e17c Merge pull request #4845 from noducks/link_fix
Force flag to prevent file already exists error.
Upstream-commit: d9c11163035d3bd3d3b4a6eea46f5f57e5428b56
Component: engine
2014-03-25 21:03:04 +10:00
05ba4a16d9 Force flag to prevent file already exists error.
Docker-DCO-1.1-Signed-off-by: No Ducks <onemannoducks@gmail.com> (github: noducks)
Upstream-commit: 8e434c314ef74618001cc95466c2b567fa0283e2
Component: engine
2014-03-25 10:26:45 +00:00
f32e1ed77b Merge pull request #4814 from noducks/master
Reminder for OSX users not to use SUDO
Upstream-commit: 30d25a3d27a80f0fcf0b9641e5d811f98e225d20
Component: engine
2014-03-25 20:15:39 +10:00
2ce68073b6 check if working dir is a directory and raise corresponding errors when making dir.
Docker-DCO-1.1-Signed-off-by: Liang-Chi Hsieh <viirya@gmail.com> (github: viirya)
Upstream-commit: 293157b8b38dd5ea5fa49d90501cc3c86717da40
Component: engine
2014-03-25 17:47:08 +08:00
df52e0a2f8 Reminder for OSX users not to use SUDO
Useful for those who haven't made it to the examples page yet. dad4a998dc

Docker-DCO-1.1-Signed-off-by: No Ducks <onemannoducks@gmail.com> (github: noducks)
Upstream-commit: 69087f2d2397b18d6dd2d7b994e24ea9814e4bcd
Component: engine
2014-03-25 09:42:59 +00:00
e26ac10f84 docker load: doc clarification
Docker-DCO-1.1-Signed-off-by: Vincent Batts <vbatts@redhat.com> (github: vbatts)
Upstream-commit: c6c7c03cddc852c42b9f047fbd5c2fb6cecf39eb
Component: engine
2014-03-24 23:36:07 -04:00
2e34f473ea Merge pull request #4839 from bflad/chef-docker-docs
Add Chef usage documentation
Upstream-commit: 267ca39921c35826ccbdb84fbbc0690bfef385d7
Component: engine
2014-03-25 12:38:45 +10:00