Commit graph

12585 commits

Author SHA1 Message Date
HuKeping
c3ed49dcdb restart: add test for recording restart policy name
Add test for recording restart policy name on
- restart=no
- restart=always
- restart=on-failure

Signed-off-by: Hu Keping <hukeping@huawei.com>
2015-01-16 17:58:26 +08:00
HuKeping
2082ff82b5 log: Add restart policy name to the inspect information of container
Under the restart policy "--restart=no", there is no record about it
in the information from docker inspect.

To keep it consistent around the three(maybe more in the future) restart
policies and distinguish with no restart policy specified cases, it's
worth to record it even though it is the default restart policy which
will not restart the container.

Signed-off-by: Hu Keping <hukeping@huawei.com>
2015-01-15 22:40:31 +08:00
Jessie Frazelle
ae493e721e Merge pull request #10110 from jfrazelle/fix-vfs-issue
ignore vfs from graphdriver warning
2015-01-14 19:54:17 -08:00
Jessica Frazelle
f88066fd43 ignore vfs from warning
Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <jess@docker.com> (github: jfrazelle)
2015-01-14 17:28:50 -08:00
Jessie Frazelle
640e0fc578 Merge pull request #9881 from tianon/json-array-of-strings
Adjust builder to validate that JSON in Dockerfiles are arrays of strings and nothing else to match how we describe them to people (and what all our existing tests already assumed)
2015-01-14 17:13:51 -08:00
Jessie Frazelle
eaecf741f0 Merge pull request #10108 from tiborvass/carry-9989
[Carry] Fix a panic where RUN [] would be supplied
2015-01-14 17:12:59 -08:00
Michael Crosby
c126a2303f Merge pull request #10106 from icecrime/win_integration_tests
Fix some Windows integration tests
2015-01-14 17:04:49 -08:00
Victor Vieux
27f69b0777 Merge pull request #10107 from jfrazelle/9328-fix-try-start-paused-container
Error should show when trying to start a paused container.
2015-01-14 17:02:23 -08:00
Tibor Vass
3183af8b19 builder: use len() > 0 instead of != nil
Signed-off-by: Tibor Vass <teabee89@gmail.com>
2015-01-14 16:55:56 -08:00
Erik Hollensbe
39343b8618 Fix a panic where RUN [] would be supplied.
Docker-DCO-1.1-Signed-off-by: Erik Hollensbe <github@hollensbe.org> (github: erikh)
2015-01-14 16:55:56 -08:00
Jessica Frazelle
02246d2d9f Error should show when trying to start a paused container.
Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <jess@docker.com> (github: jfrazelle)
2015-01-14 16:49:08 -08:00
Arnaud Porterie
e1ef33449f Take DOCKER_TEST_HOST into account
Tests no longer make the assumption that the daemon can be accessed
through unix:///var/run/docker.sock.

Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
2015-01-14 16:14:27 -08:00
Alexander Morozov
95c0f07966 Merge pull request #10093 from crosbymichael/readonly-containers
Add --read-only for read only container rootfs
2015-01-14 15:56:51 -08:00
Michael Crosby
409407091a Add --readonly for read only container rootfs
Add a --readonly flag to allow the container's root filesystem to be
mounted as readonly.  This can be used in combination with volumes to
force a container's process to only write to locations that will be
persisted.  This is useful in many cases where the admin controls where
they would like developers to write files and error on any other
locations.

Closes #7923
Closes #8752

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-01-14 15:41:31 -08:00
Michael Crosby
3118ccc6bc Merge pull request #10101 from LK4D4/fix_vet_errors
Fix vet errors
2015-01-14 15:18:20 -08:00
Michael Crosby
73bf350d3d Merge pull request #10102 from jfrazelle/windows-fix
Add build constraint for windows
2015-01-14 15:15:46 -08:00
Jessica Frazelle
798215af24 Add build constraint.
Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <jess@docker.com> (github: jfrazelle)
2015-01-14 14:40:07 -08:00
Alexander Morozov
a75b02fe72 Fix format calls as suggested by vet
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-01-14 14:12:03 -08:00
Alexander Morozov
bb96e53b0f Fix vet error about passing Mutex by value
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-01-14 14:03:00 -08:00
Alexander Morozov
5ce60217f1 Calming vet about type aliases from other package
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-01-14 14:01:36 -08:00
Victor Vieux
f67c6d313b Merge pull request #10082 from jfrazelle/10081-fix-renaming
Renaming a container with an invalid name should fail
2015-01-14 13:12:36 -08:00
Jessica Frazelle
a92281637f Renaming a container with an invalid name should fail
Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <jess@docker.com> (github: jfrazelle)
2015-01-14 12:54:23 -08:00
Michael Crosby
37b69408f8 Merge pull request #10056 from coolljt0725/add_link_accept_ID
Add --link accept container ID
2015-01-14 12:50:10 -08:00
Michael Crosby
71ab2efbfa Merge pull request #9836 from SvenDowideit/transcluded-no-sudo-note
Add a note that remote and Boot2Docker users should not type sudo
2015-01-14 12:44:53 -08:00
Jessie Frazelle
95fea08f7a Merge pull request #10072 from LK4D4/fix_mutable_net_files
Rewrite TestRunMutableNetworkFiles to avoid races
2015-01-14 11:48:46 -08:00
Tibor Vass
7d80fd6ca6 Merge pull request #10092 from docker/revert-10087-proper-netgo-thanks-rsc
Revert new netgo
2015-01-14 10:15:14 -08:00
Jessie Frazelle
e7cfb1c28b Revert "Add proper "netgo" compiling, thanks to rsc ♥"
Docker-DCO-1.1-Signed-off-by: Jessie Frazelle <jfrazelle@users.noreply.github.com> (github: jfrazelle)
2015-01-14 09:55:35 -08:00
Jessie Frazelle
5136b11514 Merge pull request #10075 from LK4D4/test_for_maxcount
Test for restarting count
2015-01-14 09:17:02 -08:00
Jessie Frazelle
355415d823 Merge pull request #10086 from tianon/properly-fix-daemon-kill-on-failure
Properly fix "daemon kill" on test failure
2015-01-14 09:13:32 -08:00
Jessie Frazelle
c05e7c4135 Merge pull request #10087 from tianon/proper-netgo-thanks-rsc
Add proper "netgo" compiling, thanks to rsc ♥
2015-01-14 09:09:18 -08:00
Lei Jitang
2292167b02 Add tests for --link
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2015-01-14 15:25:58 +08:00
Tianon Gravi
b5aba426d4 Add proper "netgo" compiling, thanks to rsc ♥
Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2015-01-13 21:35:21 -07:00
Alexander Morozov
79d30364c9 Test for restarting count
This test is for #10058
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-01-13 20:28:44 -08:00
Tianon Gravi
c18fdc3704 Properly fix "daemon kill" on test failure
Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2015-01-13 21:12:07 -07:00
Sven Dowideit
d5df948829 Add a note that remote and Boot2Docker users should not type sudo
Docker-DCO-1.1-Signed-off-by: Sven Dowideit <SvenDowideit@docker.com> (github: SvenDowideit)
2015-01-13 21:40:14 -05:00
Jessie Frazelle
c9dab702be Merge pull request #10076 from MalteJ/ipv6-docs
IPv6 docs: The ARP cache is called NDP neighbor cache in IPv6
2015-01-13 17:05:28 -08:00
Michael Crosby
e90df7c8d2 Merge pull request #10077 from crosbymichael/parallel-image-check
Parallel image lookup
2015-01-13 17:02:49 -08:00
Michael Crosby
47e3da848f Merge pull request #10080 from crosbymichael/pid-ns
Add --pid flag for staying in the host's pid namespace
2015-01-13 17:00:18 -08:00
Michael Crosby
8ac075b846 Merge pull request #10036 from HuKeping/docs-next
docs: update docker inspect part of docs
2015-01-13 16:43:42 -08:00
Michael Crosby
23b48fbe14 Merge pull request #10079 from tonistiigi/fix-attach-stdin
Fix attach stream closing issues
2015-01-13 16:40:42 -08:00
Michael Crosby
15e8f3fdd3 Add test for --pid=host
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-01-13 16:39:08 -08:00
Dan Walsh
23feaaa240 Allow the container to share the PID namespace with the host
We want to be able to use container without the PID namespace.  We basically
want containers that can manage the host os, which I call Super Privileged
Containers.  We eventually would like to get to the point where the only
namespace we use is the MNT namespace to bring the Apps userspace with it.

By eliminating the PID namespace we can get better communication between the
host and the clients and potentially tools like strace and gdb become easier
to use.  We also see tools like libvirtd running within a container telling
systemd to place a VM in a particular cgroup, we need to have communications of the PID.

I don't see us needing to share PID namespaces between containers, since this
is really what docker exec does.

So currently I see us just needing docker run --pid=host

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
2015-01-13 16:35:17 -08:00
Tonis Tiigi
28cf8fddd4 Fix attach stream closing issues
Fixes: #9860
Fixes: detach and attach tty mode

We never actually need to close container `stdin` after `stdout/stderr` finishes. We only need to close the `stdin` goroutine. In some cases this also means closing `stdin` but that is already controlled by the goroutine itself.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2015-01-14 02:03:25 +02:00
Jessie Frazelle
0eefae8e0d Merge pull request #10068 from jfrazelle/api-bump-rename
Add reference to rename endpoint in correct version & add to new
2015-01-13 15:58:36 -08:00
Michael Crosby
476cf1b906 Use channels and set workers to make image lookup safe
This refactors the starting work by the prior commits to make this safe
for access.  A maximum of 5 worker go routines are started to lookup
images on the endpoint.  Another go routine consumes the images that are
required to be pushed into a map for quick lookups.  The map is required
because the pushing of the image json and layer have to be done in the
correct order or the registry will explode in fire.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-01-13 15:52:44 -08:00
Ian Calvert
3328658929 Replace custom waiting code with a WaitGroup
Signed-off-by: Ian Calvert <ianjcalvert@gmail.com>
2015-01-13 15:32:47 -08:00
Ian Calvert
90c5ff4f06 Run the remote image presence checks in parallel
Signed-off-by: Ian Calvert <ianjcalvert@gmail.com>
2015-01-13 15:32:47 -08:00
Jessica Frazelle
ee78e3f284 Add reference to rename endpoint in correct version & add to new
Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <jess@docker.com> (github: jfrazelle)
2015-01-13 15:22:04 -08:00
Malte Janduda
c03e15c9da IPv6 docs: The ARP cache is called NDP neighbor cache in IPv6
Signed-off-by: Malte Janduda <mail@janduda.net>
2015-01-14 00:20:17 +01:00
unclejack
044d979f4e Merge pull request #10003 from vbatts/vbatts-dm_loop_file_info
devmapper: show device and loop file , if used
2015-01-14 01:15:09 +02:00