Commit graph

59 commits

Author SHA1 Message Date
Qiang Huang
0a426c47c8 Update cgroup integration tests
Cgroup integtaion tests should cover:
- docker can run sucessfully with these options
- these cgroup options are set to HostConfig as expected
- these cgroup options are really set to cgroup files as expected
- other cases (wrong value, combinations etc..)

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2015-11-30 08:40:47 +08:00
Qiang Huang
dd7b4fd651 Fix kernel memory limit
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2015-11-28 09:47:25 +08:00
Michael Crosby
249b3a9479 Merge pull request #17459 from brahmaroutu/Power_Z_CI
Build and test Docker on IBM Power and Z using gccgo. Enable CI on Po…
2015-11-19 15:50:07 -08:00
Antonio Murdaca
7929888214 Remove deprecated cli flags
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2015-11-15 10:40:01 +01:00
Srini Brahmaroutu
b1cc78b8f5 Build and test Docker on IBM Power and Z using gccgo. Enable CI on Power and Z.
Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
2015-11-14 03:16:45 +00:00
Ma Shimiao
0fbfa1449d Add support for blkio.weight_device
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
2015-11-11 23:06:36 +08:00
Vincent Demeester
7a82429b3d Use checker for docker_cli_run_unix_test.go
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2015-11-06 22:49:16 +01:00
Solomon Hykes
2519f46550 Merge pull request #17700 from calavera/remove_lxc
Remove LXC support.
2015-11-05 15:22:37 -08:00
David Calavera
157b66ad39 Remove exec-driver global daemon option.
Each platform has only a driver now.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-11-05 17:09:58 -05:00
David Calavera
3b5fac462d Remove LXC support.
The LXC driver was deprecated in Docker 1.8.
Following the deprecation rules, we can remove a deprecated feature
after two major releases. LXC won't be supported anymore starting on Docker 1.10.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-11-05 17:09:57 -05:00
Sally O'Malley
41de7a18d8 Change 'docker run' exit codes to distinguish docker/contained errors
The purpose of this PR is for users to distinguish Docker errors from
contained command errors.
This PR modifies 'docker run' exit codes to follow the chroot standard
for exit codes.
Exit status:
125 if 'docker run' itself fails
126 if contained command cannot be invoked
127 if contained command cannot be found
the exit status otherwise

Signed-off-by: Sally O'Malley <somalley@redhat.com>
2015-11-04 15:18:50 -05:00
Srini Brahmaroutu
2046ba3e3c GCCGO requires more memory and time to start containers, fixing GCCGO x86 CI
Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
2015-10-26 19:09:00 +00:00
Vincent Demeester
e4dadeed88 Merge pull request #17011 from sunyuan3/TestRunWithBlkioInvalidWeight
update TestRunWithBlkioInvalidWeight
2015-10-15 08:34:52 +02:00
Yuan Sun
d550fbb80e update TestRunWithBlkioInvalidWeight
Signed-off-by: Yuan Sun <sunyuan3@huawei.com>
2015-10-14 16:20:52 +08:00
Jessica Frazelle
28ad7c588f update tests
Signed-off-by: Jessica Frazelle <acidburn@docker.com>
2015-10-13 15:52:14 -07:00
Antonio Murdaca
06f0d03ced daemon: execdriver: lxc: fix set memory swap
On LXC memory swap was only set to memory_limit*2 even if a value for
memory swap was provided. This patch fix this behavior to be the same
as the native driver and set correct memory swap in the template.
Also add a test specifically for LXC but w/o adding a new test
requirement.

Signed-off-by: Antonio Murdaca <runcom@linux.com>
2015-10-13 14:46:59 -07:00
Jessica Frazelle
ea3afdad61 add test-integration-cli specifics for userns
Signed-off-by: Jessica Frazelle <acidburn@docker.com>
Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <acidburn@docker.com>
2015-10-09 20:50:27 -04:00
Yuan Sun
042d08a2a8 add TestRunInValidCPUShares
Signed-off-by: Yuan Sun <sunyuan3@huawei.com>
2015-10-08 10:04:51 +08:00
Jess Frazelle
698e14902a Merge pull request #16159 from runcom/validate-cpuset-cpus
Validate --cpuset-cpus, --cpuset-mems
2015-10-02 11:30:46 -07:00
Yuan Sun
3571814dc5 Update TestRunWithSwappinessInvalid.
Signed-off-by: Yuan Sun <sunyuan3@huawei.com>
2015-09-28 18:13:21 +08:00
Antonio Murdaca
94464e3a5e Validate --cpuset-cpus, --cpuset-mems
Before this patch libcontainer badly errored out with `invalid
argument` or `numerical result out of range` while trying to write
to cpuset.cpus or cpuset.mems with an invalid value provided.
This patch adds validation to --cpuset-cpus and --cpuset-mems flag along with
validation based on system's available cpus/mems before starting a container.

Signed-off-by: Antonio Murdaca <runcom@linux.com>
2015-09-27 16:38:58 +02:00
Jess Frazelle
84b53c8d87 Merge pull request #14579 from hqhq/hq_add_softlimit
Add support for memory reservation
2015-09-24 12:11:36 -07:00
Yuan Sun
b89fdc120e update TestRunWithKernelMemory
Signed-off-by: Yuan Sun <sunyuan3@huawei.com>
2015-09-24 08:41:35 +08:00
qhuang
aa1780997f Add support for memory reservation
Signed-off-by: qhuang <qhuang@10.0.2.15>
2015-09-23 14:02:45 +08:00
Yuan Sun
ab39a4c981 Add the TestRunSwapLessThanMemoryLimit case.
Signed-off-by: Yuan Sun <sunyuan3@huawei.com>
2015-09-21 22:12:19 +08:00
Antonio Murdaca
0b8b8ed9e9 integration-cli: fix tests with memory limit
If you don't have cgroup swap memory support, `dockerCmd`'s output in
these tests will be polluted by a warning from the daemon and will fail
the tests.
No need to have memory swap support for these tests to run as it will
be reset to -1 and everything will continue correctly.

Signed-off-by: Antonio Murdaca <runcom@linux.com>
2015-09-19 00:07:40 +02:00
Yuan Sun
cf6a53642a Correct wrong comment for TestRunWithoutMemoryswapLimit case.
Signed-off-by: Yuan Sun <sunyuan3@huawei.com>
2015-09-18 08:28:36 +08:00
Antonio Murdaca
e5a26ec081 Deprecate -c cli short variant flag in docker run
Signed-off-by: Antonio Murdaca <runcom@linux.com>
2015-09-17 15:48:48 +02:00
David Calavera
fb01c2ea3c Merge pull request #16350 from cpuguy83/fix_error_on_dev-snd_test
Skip TestRunDeviceDirectory when no /dev/snd
2015-09-16 13:56:11 -07:00
Srini Brahmaroutu
2c53643b33 adding a Dockerfile.gccgo to use gccgo compiler instead of go compiler.
temporarily disabling registry builds as crypto package is broken with gccgo.

Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
2015-09-16 18:56:01 +00:00
Brian Goff
88b895111b Skip TestRunDeviceDirectory when no /dev/snd
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2015-09-16 14:43:30 -04:00
David Calavera
0e50d946a2 Signal to stop a container.
Allow to set the signal to stop a container in `docker run`:
- Use `--stop-signal` with docker-run to set the default signal the container will use to exit.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-09-10 19:56:05 -04:00
John Howard
d7eb85bb1f Move run tests out of unix files
Signed-off-by: John Howard <jhoward@microsoft.com>
2015-09-01 09:42:19 -07:00
Lei Jitang
c340ca4f5d Add some missing cgroup test require and refactor the require check.
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2015-08-24 11:37:11 +08:00
Brian Goff
5929502b4e Merge pull request #15412 from vdemeester/dont-sleep-too-much
time.Sleep in integration tests — comment and waitRun/waitInspect
2015-08-21 20:43:55 -04:00
Qiang Huang
b6f1b4ad35 Add support for kernel memory limit
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2015-08-19 23:56:55 +08:00
Vincent Demeester
799d9605d6 Remove/Comment time.Sleep in integration tests
Remove what seems unnecessary time.Sleep (1 second even) and comment the
ones that seemed necessary.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2015-08-18 20:36:08 +02:00
Brian Goff
693ba98cb9 Don't pass check.C to dockerCmdWithError
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2015-07-27 14:33:32 -04:00
Ben Firshman
6b3c928140 Fix golint warnings for integration-cli
Signed-off-by: Ben Firshman <ben@firshman.co.uk>
2015-07-22 14:03:50 +01:00
Alexander Morozov
844fc5f77c Fix cgroup parent tests
After merging mounting cgroups in container this tests doing wrong
checks. Cgroup paths could be prepended by other cgroups from host.

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-07-21 08:59:17 -07:00
Hu Keping
71868228c7 Refactor : Use dockerCmd in integration-cli tests
Signed-off-by: Hu Keping <hukeping@huawei.com>
2015-07-17 04:07:12 +08:00
Qiang Huang
f18fb5b3ef Add cgroup bind mount by default
Libcontainer already supported mount container's own cgroup into
container, with this patch, we can see container's own cgroup info
in container.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2015-07-10 13:12:09 +08:00
John Howard
c1b524486c Fix Windows CI fail due to GH13866 and patch up tests
Signed-off-by: John Howard <jhoward@microsoft.com>
2015-07-09 10:09:45 -07:00
David Calavera
a914101296 Do not require cgroups capabilities on windows to run the integration tests.
Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-05-29 11:42:40 -07:00
Antonio Murdaca
4203230cbb c.Fatal won't fail and exit test inside a goroutine, errors should be handled outside with a channel
Signed-off-by: Antonio Murdaca <me@runcom.ninja>
2015-04-29 17:02:22 +02:00
David Mackey
3941623fbc trivial: typo cleanup
Signed-off-by: David Mackey <tdmackey@booleanhaiku.com>
2015-04-27 13:35:08 -07:00
Alexander Morozov
dc944ea7e4 Use suite for integration-cli
It prints test name and duration for each test.
Also performs deleteAllContainers after each test.

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-04-21 10:28:52 -07:00
Brian Goff
f7538c77ef Move TestRunDetach to integration-cli
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2015-04-13 20:48:24 -04:00
Megan Kostick
05dcf26199 Fixing fail message in TestRunDeviceDirectory
Signed-off-by: Megan Kostick <mkostick@us.ibm.com>
2015-04-07 13:14:47 -07:00
Jessica Frazelle
f472c7236f fix device test on lxc, on lxc in contianers there are no dirs with devices in /dev, but this works outside a container...
Docker-DCO-1.1-Signed-off-by: Jessie Frazelle <princess@docker.com> (github: jfrazelle)
2015-04-01 17:47:36 -07:00