Commit Graph

1557 Commits

Author SHA1 Message Date
John Howard 9f80f3f181 Windows: Factor out CloseExecFrom
Signed-off-by: John Howard <jhoward@microsoft.com>
2015-06-26 20:13:17 -07:00
Michael Crosby b6c196fd18 Merge pull request #47 from LK4D4/fix_abs_path
Fix absolute path getting for runc binary
2015-06-26 17:46:49 -07:00
Alexander Morozov 4d6c19af8b Fix absolute path getting for runc binary
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-06-26 14:56:53 -07:00
Colin Walters 83d503e9d7 linux: Don't prepend process' cwd if rootfs path is already absolute
If I provide a path starting with `/` I expect that to be honored;
otherwise I have to explicitly `(cd /; /path/to/runc)`.

Signed-off-by: Colin Walters <walters@redhat.com>
2015-06-26 17:39:38 -04:00
Michael Crosby a1c3018cc4 Merge pull request #23 from duglin/tweakHelp
Minor README tweaks to help newbies
2015-06-26 13:43:16 -07:00
Mrunal Patel d5e97edbbc Merge pull request #44 from crosbymichael/move-docs
Move libcontainer documenation to root of repo
2015-06-26 12:03:46 -07:00
Michael Crosby f637539def Move libcontainer documenation to root of repo
This moves much of the documentation on contributing and maintainer the
codebase from the libcontainer sub directory to the root of the repo.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-06-26 11:50:46 -07:00
Mrunal Patel 8d0ae52adc Merge pull request #42 from crosbymichael/notice
Add notcie about config format changes
2015-06-26 11:37:27 -07:00
Michael Crosby 5e90d85d26 Add notcie about config format changes
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-06-26 11:31:00 -07:00
Alexander Morozov cc16e6b032 Merge pull request #30 from estesp/missing-rootfs-check
Make startup errors a bit friendlier
2015-06-26 09:03:49 -07:00
Mrunal Patel 3fec3b37bf Merge pull request #33 from estesp/typo-and-usage-format
Update usage content and fix typos
2015-06-25 17:17:42 -07:00
Phil Estes 936ca1b78d Update usage content and fix typos
1. Remove mention of nsinit (removed from the repo)
2. Make basic usage text a bit more informative; fix typo
3. Fix typo in panic() message (that should never be seen) :)

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
2015-06-25 16:26:31 -07:00
Michael Timbrook f8c4890a2f Added all dependency to install in Makefile 2015-06-25 13:42:15 -07:00
Michael Crosby f49826cf7e Merge pull request #31 from estesp/allow-hyphen-in-id
Allow hyphen in "id" (based on `cwd` pathname)
2015-06-25 11:30:45 -07:00
Phil Estes d95050084b Allow hyphen in "id" (based on `cwd` pathname)
A directory with a hyphen currently generates an InvalidId error because
of the regex in libcontainer.  I don't believe there is any reason a
hyphen should be disallowed.

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
2015-06-25 11:27:25 -07:00
Doug Davis 1c81b08c8c Minor README tweaks to help newbies
Signed-off-by: Doug Davis <dug@us.ibm.com>
2015-06-25 10:53:42 -07:00
Phil Estes 9c56596f24 Make startup errors a bit friendlier
A couple minor changes to error handling in startup:
1. Don't dump full help/usage text when the only problem is `runc` wasn't started under
root privileges
2. Check for rootfs and make error clear to user when it doesn't exist
3. Change fatal to logrus.Fatal to get nicer output with simple error
message

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
2015-06-25 00:19:44 -07:00
Mrunal Patel d05943b95f Merge pull request #28 from estesp/allow-relative-runc
Allow runc to be executed as a relative path
2015-06-24 19:24:55 -07:00
Stephen Day 622dd02741 Merge pull request #14 from carmark/master
make the install steps more clear in README.md
2015-06-24 18:21:26 -07:00
Mrunal Patel 7927dc2f09 Merge pull request #29 from estesp/minor-typo
Fix function name typo
2015-06-24 17:17:22 -07:00
Phil Estes 7eb6ff005c Fix function name typo
Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
2015-06-24 17:14:30 -07:00
Lei Xue f4f6938448 Update README.md 2015-06-25 08:04:12 +08:00
Phil Estes 1e24fe814d Allow runc to be executed as a relative path
This allows "./runc .." instead of adding it to $PATH location

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
2015-06-24 11:14:46 -07:00
Alexander Morozov 8ad8d40744 Merge pull request #22 from lizf-os/remove-nsinit-from-comments
Remove nsinit from comments
2015-06-24 09:12:55 -07:00
Zefan Li cbf3d12cb3 Remove nsinit from comments
Signed-off-by: Zefan Li <lizefan@huawei.com>
2015-06-24 11:29:50 +08:00
Mrunal Patel dc185c6e67 Merge pull request #20 from estesp/fix-memory-swappiness-init
Initialize memory.swappiness cgroup to -1
2015-06-23 16:17:10 -07:00
Alexander Morozov f74baf28f9 Merge pull request #21 from unclejack/gofmt_pass
libcontainer: gofmt pass
2015-06-23 16:06:18 -07:00
unclejack 9408c09d50 libcontainer: gofmt pass 2015-06-24 01:57:42 +03:00
Phil Estes 9c732ae501 Initialize memory.swappiness cgroup to -1
Set up memory.swappiness in cgroup config so write is not attempted
unless specifically set.  Fixes running runc on kernels which still have
the cgroup hierarchy write limitation.

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
2015-06-23 12:26:01 -07:00
Michael Crosby 5336c57704 Merge pull request #8 from LK4D4/remove_nsinit_readme
Remove nsinit from libcontainer README.md
2015-06-23 11:33:02 -07:00
Michael Crosby a89dd6cc74 Merge pull request #10 from LK4D4/fix_panic_in_tests
Fix panic in seccomp test on error
2015-06-23 11:32:29 -07:00
Lei Xue 682f398e8a Update README.md 2015-06-23 12:16:51 +08:00
Lei Xue f9806effff make the install steps more clear in README.md 2015-06-23 11:39:38 +08:00
Alexander Morozov 5c56d28043 Fix panic in seccomp test on error
It can happen if newContainer is failed. Now test shows real error from
newContainer instead of trace.

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-06-22 19:26:33 -07:00
David Calavera b7ec287550 Merge pull request #11 from justjake/patch-1
Change "... JSON Format;" to "... JSON Format:"
2015-06-22 17:21:43 -07:00
Jake Teton-Landis 5ebf4c94e7 Change "... JSON Format;" to "... JSON Format:" 2015-06-22 11:09:41 -07:00
Alexander Morozov 4ac21b5fd3 Remove nsinit from libcontainer README.md
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-06-22 10:34:38 -07:00
Michael Crosby f20d95b6f2 Use godeps for building of vendored files
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-06-22 09:23:17 -07:00
Michael Crosby 9fac183294 Initial commit of runc binary
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-06-21 19:34:13 -07:00
Michael Crosby 080df7ab88 Update import paths for new repository
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-06-21 19:29:59 -07:00
Michael Crosby 8f97d39dd2 Move libcontainer into subdirectory
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-06-21 19:29:15 -07:00
Michael Crosby 4b5bf88a08 Remove nsinit
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-06-21 19:28:36 -07:00
Alexander Morozov b675770455 Merge pull request #643 from runcom/cleanup-unused
Remove unused code
2015-06-20 09:02:03 -07:00
Antonio Murdaca eb0408b199 Remove unused code
Signed-off-by: Antonio Murdaca <runcom@linux.com>
2015-06-20 14:53:44 +02:00
Alexander Morozov a4cc960eaf Merge pull request #642 from crosbymichael/parent-cgroup
Ensure all parent dirs are properly setup
2015-06-19 16:41:48 -07:00
Michael Crosby 5e729ced92 Ensure all parent dirs are properly setup
Even if libcontainer does not create the directories for the cpuset
cgroup we should ensure that they are properly populated with the
parent's cpus and mems values.  Some systems create the directory
structures but do not correctly populate the values and causes our
implementation to fail.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-06-19 15:56:12 -07:00
Daniel, Dao Quang Minh ae8fc2f8de Merge pull request #640 from estesp/nsinit-memory-swappiness
Fix nsinit to configure default cgroup entry for MemorySwappiness
2015-06-19 12:54:29 +08:00
Phil Estes e1128da32a Fix nsinit to configure default cgroup entry for MemorySwappiness
As related to #639, this at least makes the "nsinit" consumer of
libcontainer initialize the value to "-1" and also allows the user to
specify a setting for the container.

This is an analog to Docker PR docker/docker#14030.

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
2015-06-18 23:42:51 -04:00
Mrunal Patel 107b7ed268 Merge pull request #638 from lizf-os/fix-check-cpu-shares
Avoid trying to access cpu.shares when it doesn't exist
2015-06-18 13:41:58 -07:00
Rohit Jnagal ed1146a8ee Merge pull request #637 from hqhq/hq_fix_kmem_cgroup
Fix kmem limit set
2015-06-18 09:45:52 -07:00