Commit graph

593 commits

Author SHA1 Message Date
Eric Windisch
87376c3add Introduce a dedicated unconfined AA policy
By using the 'unconfined' policy for privileged
containers, we have inherited the host's apparmor
policies, which really make no sense in the
context of the container's filesystem.

For instance, policies written against
the paths of binaries such as '/usr/sbin/tcpdump'
can be easily circumvented by moving the binary
within the container filesystem.

Fixes GH#5490

Signed-off-by: Eric Windisch <eric@windisch.us>
2015-07-22 11:28:32 -04:00
Alexander Morozov
380959dd68 Merge pull request #14609 from ewindisch/apparmor-policy
Move AppArmor policy to contrib & deb packaging
2015-07-21 08:48:02 -07:00
Eric Windisch
80d99236c1 Move AppArmor policy to contrib & deb packaging
The automatic installation of AppArmor policies prevents the
management of custom, site-specific apparmor policies for the
default container profile. Furthermore, this change will allow
a future policy for the engine itself to be written without demanding
the engine be able to arbitrarily create and manage AppArmor policies.

- Add deb package suggests for apparmor.
- Ubuntu postinst use aa-status & fix policy path
- Add the policies to the debian packages.
- Add apparmor tests for writing proc files
Additional restrictions against modifying files in proc
are enforced by AppArmor. Ensure that AppArmor is preventing
access to these files, not simply Docker's configuration of proc.
- Remove /proc/k?mem from AA policy
The path to mem and kmem are in /dev, not /proc
and cannot be restricted successfully through AppArmor.
The device cgroup will need to be sufficient here.
- Load contrib/apparmor during integration tests
Note that this is somewhat dirty because we
cannot restore the host to its original configuration.
However, it should be noted that prior to this patch
series, the Docker daemon itself was loading apparmor
policy from within the tests, so this is no dirtier or
uglier than the status-quo.

Signed-off-by: Eric Windisch <eric@windisch.us>
2015-07-21 11:05:53 -04:00
Sebastiaan van Stijn
18ca5d7c0e Remove reference to CENTOS6 from generate script
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2015-07-21 01:21:33 +02:00
Jessica Frazelle
af5fb9b7d0 remove centos6 from rpm builder
Signed-off-by: Jessica Frazelle <princess@docker.com>
2015-07-19 14:30:48 -07:00
Jessica Frazelle
4a5fd6c0f9 add tianon's suites.sh file
Signed-off-by: Jessica Frazelle <princess@docker.com>
2015-07-15 12:48:49 -07:00
Jessie Frazelle
386f11a63d Merge pull request #14555 from sdurrheimer/master
Zsh completion updates and improvements
2015-07-15 10:40:41 -07:00
Jessie Frazelle
cf09e435c8 Merge pull request #14608 from vincentbernat/fix/zsh-reviewers
zsh: remove Vincent Bernat from reviewers for ZSH completion
2015-07-14 07:08:06 -07:00
Steve Durrheimer
91a2d9cc7d Several cosmetic improvements in zsh completion
Signed-off-by: Steve Durrheimer <s.durrheimer@gmail.com>
2015-07-14 11:34:33 +02:00
Steve Durrheimer
12f67141f9 Zsh completion update for the following commits:
- Add fluentd logging driver to zsh completion #12876
- Add inspect --type flag to zsh completion #13187
- Respect -H option in zsh completion #13195
- Fix number of argument limit for pause and unpause in zsh completion

Signed-off-by: Steve Durrheimer <s.durrheimer@gmail.com>
2015-07-14 11:32:26 +02:00
Vincent Bernat
5dbb217bcb zsh: remove Vincent Bernat from reviewers for ZSH completion
Signed-off-by: Vincent Bernat <vincent@bernat.im>
2015-07-13 23:15:16 +02:00
Mrunal Patel
d77d0268eb Adds documentation for additional groups.
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2015-07-13 14:47:28 -04:00
Jessie Frazelle
0badebe734 Merge pull request #14426 from albers/completion-events
Add some missing events to bash completion
2015-07-13 10:05:36 -07:00
Avi Miller
f18c4f23cc Change generate.sh so that the yum command for packages remains generic across distros.
Signed-off-by: Avi Miller <avi.miller@oracle.com>
2015-07-10 07:34:47 +10:00
Avi Miller
0117330ae7 Add support for building docker-engine RPM on Oracle Linux 7.
Signed-off-by: Avi Miller <avi.miller@oracle.com>
2015-07-08 16:12:19 +10:00
Jessie Frazelle
16f8afb451 Merge pull request #14369 from maximkulkin/14123-dockerize-disk-with-non-en-locale
Fix dockerize-disk.sh working in non-en locale
2015-07-07 17:51:29 -07:00
Harald Albers
ea26b38784 Add some missing events to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2015-07-07 09:04:15 +02:00
Jessica Frazelle
76a853de6e fix rpms
Signed-off-by: Jessica Frazelle <princess@docker.com>
2015-07-06 14:14:26 -07:00
Maxim Kulkin
8630ad1530 Fix dockerize-disk.sh working in non-en locale
One part of script relies on messages that are
output by some system tool. In non-en locale
those messages get localized which breaks the
script.
This patch enforces en locale for that system
tool.

Signed-off-by: Maxim Kulkin <maxim.kulkin@gmail.com>
2015-07-02 16:08:12 -07:00
Shishir Mahajan
2cb74e6915 Flag Addition: --type flag added for docker inspect command
Signed-off-by: Shishir Mahajan <shishir.mahajan@redhat.com>
2015-07-01 12:14:01 -04:00
Steve Durrheimer
b2cc6f1b47 Update the zsh completion
Signed-off-by: Steve Durrheimer <s.durrheimer@gmail.com>
2015-06-21 17:33:07 +02:00
Jessie Frazelle
748814a97a Merge pull request #13935 from asbjornenge/tm_syntax_updates
TM syntax updates
2015-06-15 16:12:22 -07:00
Michael Crosby
3f11e05db2 Merge pull request #13942 from calavera/fix_unshare_mount_regression
Fix regression bind mounting shared.
2015-06-15 11:25:35 -07:00
David Calavera
d8592eaff8 Revert "contrib/init: unshare mount namespace for inits"
This reverts commit b6569b6b82.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-06-15 10:35:17 -07:00
Asbjørn Enge
dfec4a48c7 Various cleanups added to asbjornenge/Docker.tmbundle (by the TM maintainer) and support for the LABEL instruction
Docker-DCO-1.1-Signed-off-by: Asbjorn Enge <asbjorn@hanafjedle.net> (github: asbjornenge)
2015-06-15 00:04:05 +02:00
Asbjørn Enge
ac8cbf4952 Updated TextMate install instruction - this bundle is not included in TM 😄 :rocket
Docker-DCO-1.1-Signed-off-by: Asbjorn Enge <asbjorn@hanafjedle.net> (github: asbjornenge)
2015-06-15 00:02:10 +02:00
Mary Anthony
cd44018856 Carry of PR #13520
Removinig files

Signed-off-by: Mary Anthony <mary@docker.com>
2015-06-13 09:27:30 -07:00
Mary Anthony
eacae64bd8 Moving man pages out of docs
Adding in other areas per comments
Updating with comments; equalizing generating man page info
Updating with duglin's comments
Doug is right here again;fixing.

Signed-off-by: Mary Anthony <mary@docker.com>
2015-06-10 13:43:35 -07:00
Tianon Gravi
969cb545ae Merge pull request #13546 from hqhq/hq_checkconfig_rescount
Don't check RESOURCE_COUNTERS in new kernel
2015-06-08 14:43:17 -07:00
Eric-Olivier Lamey
dbf5e36fd6 Fix docs URL in systemd service file.
Fixes #13799.

Signed-off-by: Eric-Olivier Lamey <eo@lamey.me>
2015-06-08 10:21:43 +00:00
Qiang Huang
8bfc8102be Don't check RESOURCE_COUNTERS in new kernel
Closes: #13543

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2015-06-03 17:26:39 +08:00
Jessie Frazelle
d96ca04f24 Merge pull request #13601 from tianon/precise
Finally add precise/12.04 as a build-deb target
2015-05-29 14:35:07 -07:00
Jessie Frazelle
4d9191e15d Merge pull request #13604 from tianon/vim-embedded-shell
Add embedded shell script highlight to vim syntax
2015-05-29 14:17:07 -07:00
Tianon Gravi
e02744404d Adjust vim ftdetect to match "Dockerfile", "dockerfile", and "Dockerfile.*" which are all reasonably safe to assume "this is a Dockerfile"
Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2015-05-29 13:46:51 -07:00
Tianon Gravi
62d3b1bf2e Add embedded shell script highlight to vim syntax
This highlights `RUN`, `CMD`, and `ENTRYPOINT` lines using shell highlighting.  It doesn't bother detecting the JSON forms, but that's OK because JSON arrays highlight pretty reasonably with shell highlights. :)

Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2015-05-29 13:39:37 -07:00
Tianon Gravi
98180b8954 Finally add precise/12.04 as a build-deb target
Ubuntu Precise has a number of warts that made it non-trivial to add initially, but I've managed to work through some of them and come up with a working build.  Two important parts to note are that it has neither the `btrfs` nor the `devicemapper` graphdriver backends since `btrfs-tools` and `libdevmapper-dev` in the precise repositories are too ancient for them to even compile.

Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2015-05-29 12:55:58 -07:00
Harald Albers
b2832dffe5 Update bash completion for 1.7.0
Signed-off-by: Harald Albers <github@albersweb.de>
2015-05-29 12:42:59 +02:00
David Calavera
f99a962742 Merge pull request #13539 from tianon/deb-ubuntu-wily
Add Ubuntu Wily (15.10) as a build-deb target
2015-05-28 11:01:27 -07:00
David Calavera
0256bbdebb Merge pull request #13039 from stevenbrichards/13031-Upstart
Fix check for upstart not detecting properly
2015-05-28 10:38:55 -07:00
Steven Richards
e5ff643aed Fixes #13031 - Check for upstart or init is not detecting properly
This will now properly check whether /etc/init.d/docker or service docker is
invoking the script and respond to the user accordingly.

Signed-off-by: Steven Richards <steven@axiomzen.co>
2015-05-28 09:52:05 -07:00
Tianon Gravi
38c77ba876 Add Ubuntu Wily (15.10) as a build-deb target
Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2015-05-28 01:06:11 -07:00
Tianon Gravi
96903c837f Add fedora:22 to our rpm targets
Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2015-05-28 01:01:45 -07:00
Jessica Frazelle
40b71adee3 Revert "Add docker exec run a command in privileged mode"
This reverts commit 72a500e9e5.

Signed-off-by: Jessica Frazelle <princess@docker.com>

Conflicts:
	daemon/execdriver/native/exec.go
	integration-cli/docker_cli_exec_test.go
	runconfig/exec.go
2015-05-26 14:12:16 -07:00
Alexander Morozov
6cc4cf7c0c Add BRIDGE_NETFILTER to check-config.sh
It is needed to use network with --userland-proxy=false and for
--icc=false

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-05-22 10:46:55 -07:00
Alexander Morozov
ceca037d05 Add optional CONFIG_BLK_CGROUP and CONFIG_IOSCHED_CFQ to check-config.sh
It is needed for blkio.weight support

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-05-22 10:41:29 -07:00
Jessie Frazelle
366fe46c6a Merge pull request #13326 from tianon/squeeze-lts
Fix "squeeze" detection in contrib/mkimage/debootstrap
2015-05-20 17:41:27 -07:00
Tianon Gravi
f74d9b8672 Merge pull request #13195 from albers/completion-custom-host
respect -H in bash completion
2015-05-20 17:31:16 -07:00
Tianon Gravi
28465588d0 Merge pull request #13241 from hqhq/hq_enhance_checkconfig
Enhance check-config.sh
2015-05-20 17:25:30 -07:00
David Xia
2f9e7a067a Increase upstart kill timeout to 20 seconds
Give Docker more time to kill containers before upstart kills Docker.
The default kill timeout is 5 seconds.
This will help decrease the chance of but not eliminate the chance of
orphaned container processes.

Signed-off-by: David Xia <dxia@spotify.com>
2015-05-20 14:20:46 -04:00
Tianon Gravi
c64466fb68 Fix "squeeze" detection in contrib/mkimage/debootstrap
This stops us from erroneously adding "squeeze-lts" to "oldstable" which is now "wheezy", not "squeeze" (but "oldoldstable" _is_ squeeze, hence the new check on `/etc/debian_version` being `6.*` instead, and done as a `case` for the eventual addition of `wheezy-lts`, etc).

Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2015-05-19 09:38:27 -07:00