Commit Graph

41 Commits

Author SHA1 Message Date
Michael Crosby e58671e530 Add --all flag to kill
This allows a user to send a signal to all the processes in the
container within a single atomic action to avoid new processes being
forked off before the signal can be sent.

This is basically taking functionality that we already use being
`delete` and exposing it ok the `kill` command by adding a flag.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-11-08 09:35:02 -08:00
Zhang Wei 6cd425be2b Allow update rt_period_us and rt_runtime_us
Currently runc already supports setting realtime runtime and period
before container processes start, this commit will add update support
for realtime scheduler resources.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
2016-11-04 18:57:22 +08:00
Michael Crosby 843bab90bc Merge pull request #1161 from rajasec/updateresource
Small correction in update resource file usage
2016-10-31 10:20:47 -07:00
rajasec 3db2c43b48 man page update for delete command
Signed-off-by: rajasec <rajasec79@gmail.com>
2016-10-29 20:45:11 +05:30
rajasec 2d0d936b76 Small correction in update resource file usage
Signed-off-by: rajasec <rajasec79@gmail.com>
2016-10-28 22:58:08 +05:30
Wang Long ed6c5c038c update the man for runc delete command
This patch also change the description in delete.go in order to
keep consistent with the mannual.

Signed-off-by: Wang Long <long.wanglong@huawei.com>
2016-10-18 12:18:10 +08:00
Michael Crosby 4dcc0466e2 Merge pull request #1074 from datawolf/multi-containers
start multi-containers with `runc start` command
2016-10-17 14:31:04 -07:00
Wang Long 2f5c0afbbc pause and resume multi-containers
With this patch, `runc pasue` and `runc resume` can
pause and resume multi-containers.

Signed-off-by: Wang Long <long.wanglong@huawei.com>
2016-10-17 19:44:08 +08:00
Wang Long 74bfe500e4 start mulit-containers with `runc start` command
With this patch, `runc start` command can start mulit-containers
at one command this patch also checks the argument of the `start`
command.

root@ubuntu:# runc list
ID          PID         STATUS      BUNDLE         CREATED
a           0           stopped     /mycontainer   2016-09-23T08:56:42.754026567Z
b           62979       created     /mycontainer   2016-09-23T09:01:36.421976458Z
c           62993       running     /mycontainer   2016-09-23T09:01:38.105940389Z
d           63006       created     /mycontainer   2016-09-23T09:01:39.65441942Z
e           63020       created     /mycontainer   2016-09-23T09:01:40.989995515Z
root@ubuntu:# runc start
runc: "start" requires a minimum of 1 argument
root@ubuntu:# runc start a b c d e f
cannot start a container that has run and stopped
cannot start an already running container
container f is not exist
all or part of the containers start failed
root@ubuntu:# runc list
ID          PID         STATUS      BUNDLE         CREATED
a           0           stopped     /mycontainer   2016-09-23T08:56:42.754026567Z
b           62979       running     /mycontainer   2016-09-23T09:01:36.421976458Z
c           62993       running     /mycontainer   2016-09-23T09:01:38.105940389Z
d           63006       running     /mycontainer   2016-09-23T09:01:39.65441942Z
e           63020       running     /mycontainer   2016-09-23T09:01:40.989995515Z

Signed-off-by: Wang Long <long.wanglong@huawei.com>
2016-10-08 11:57:25 +08:00
Qiang Huang dc9be6cab1 Merge pull request #933 from zhaoleidd/workaround_for_ps
cli: Workaround for ps's argument
2016-08-27 10:57:17 +08:00
Mrunal Patel 9b53b362e2 Merge pull request #906 from TristanCacqueray/master
Add "--" exec cli support for command arguments
2016-08-26 10:35:26 -07:00
Tristan Cacqueray c562e4cd91 exec: Support command arguments
This enables support for exec command argument starting with a '-'.
This uses the usual argument separator '--', for example:
  runc exec containerid -- ps -afx

Without this, cli interprets command argument and fails with
'flag provided but not defined'.

Signed-off-by: Tristan Cacqueray <tdecacqu@redhat.com>
2016-08-26 02:01:40 +00:00
Aleksa Sarai a56fc8264c
Merge branch 'pr-878'
Closes #878 [Adjust man pages for create start split].
2016-08-24 18:35:11 +10:00
Qiang Huang 7e3eb32561 Add runc list man change
Follow up https://github.com/opencontainers/runc/pull/939

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2016-07-19 08:56:25 +08:00
Zhao Lei f5a95fa244 cli: Workaround for ps's argument
Currently, ps command can not support argument:
(But following usage is in manual)
 | # ./runc ps 123 -ef
 | Incorrect Usage.
 |
 | NAME:
 |    runc ps - ps displays the processes running inside a container
 |
 | USAGE:
 |    runc ps [command options] <container-id> [ps options]
 |
 | OPTIONS:
 |    --format value, -f value  select one of: table or json
 |
 | flag provided but not defined: -ef
 | #

Instead of using odd command like:
 | # ./runc ps -- 123 -ef

We can make it seems little better:
 | # ./runc ps 123 -- -ef
 | UID        PID  PPID  C STIME TTY          TIME CMD
 | root     29046 29038  0 11:18 pts/2    00:00:00 sh
 | #

This patch also fixed manual which can not working in current
code.

Closes #788

Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-07-07 18:17:13 +08:00
Zhao Lei 71929e0f9d Fix ps argument manual
Argument of "ps options" for ps command is a optional parameter.
Should use [] instead of <> in manual.

Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-06-17 19:07:30 +08:00
Qiang Huang c669b8d156 Adjust man pages for create start split
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2016-06-12 20:38:45 +08:00
Qiang Huang d8e840e8f9 Use cli default value for list format
For consistency.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2016-06-04 16:57:13 +08:00
Qiang Huang 2503fca35d Update man pages to refect the latest cli change
The major change is the description of options, change
it as the latest cli help message shows, which specify
a "value" after an option if it takes value, and add
(default: xxx) if the option has a default value.

This also includes some other minor consistency fixes.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2016-05-28 13:33:57 +08:00
Zhao Lei 34d100f970 manual: add manual for ps command
This patch add manual for ps command, and remove remove example
for --format command, which is not necessary.

Suggested-by: Aleksa Sarai <asarai@suse.de>
Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-05-25 17:32:14 +08:00
Zhao Lei f5b674c914 manual: restore: Update contents with source
This patch add losted --no-subreaper and --no-pivot options in
manual:
 # ./runc restore --help
 ..
 OPTIONS:
   ...
   --no-subreaper               disable the use of the subreaper used to reap reparented processes
   --no-pivot                   do not use pivot root to jail process inside rootfs.  This should be used whenever the rootfs is on top of a ramdisk
 #

Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-05-25 17:23:07 +08:00
Zhao Lei 7d5779fdee manual: list: Move description contents into OPTIONS field
The description contents in manual is for --format argument
actually, see:
 # ./runc list --help
 ...
 OPTIONS:
    --format, -f         select one of: table or json.

 The default format is table.  The following will output the list of containers
 in json format:

     # runc list -f json
    --quiet, -q  display only container IDs
 #

This patch move above content into right place, and remove the command
example which is not necessary.

Suggested-by: Aleksa Sarai <asarai@suse.de>
Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-05-25 17:18:30 +08:00
Zhao Lei aedafa9965 manual: runc-exec: Add losted --no-subreaper argument
--no-subreaper's description exist in code but not in manual:
 # ./runc exec --help
 ...
 OPTIONS:
   ...
   --no-subreaper                               disable the use of the subreaper used to reap reparented processes
 #

Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-05-25 10:48:11 +08:00
Zhao Lei f6e4d7ba7c manual: Update runc-events.8.md with source
--events argument's usage was updated by:
commit:a62dbf48b0fe5e2e28e3cc9dc80a70d2ec5ebc25
We need to update manual together.

This patch also removes last useless blank line
in manual.

Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-05-25 10:48:11 +08:00
Zhao Lei 8cd952f0a2 manual: Unify EXAMPLE title in code and manual
There are 3 types of EXAMPLE title in manual and code:
1: "# EXAMPLE"
   runc-delete.8.md
   runc-exec.8.md
   runc-kill.8.md
2: "EXAMPE:"
   runc-spec.8.md
3: EXAMPLE title exist in manual, but not exist in code's --help output
   delete.go
   exec.go
   kill.go

This patch unified above format, and deleted some useless blanks.

Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-05-25 10:48:11 +08:00
Zhao Lei a6a0cdf53d manual: Use SYNOPSIS instead of USAGE in man/runc-checkpoint.8.md
Reason1:
 other runc manual are using word of "SYNOPSIS"
 # grep USAGE man/*
 # man/runc-checkpoint.8.md:#USAGE
 #
 # grep SYNOPSIS man/*
 man/runc-checkpoint.8.md:# SYNOPSIS
 man/runc-delete.8.md:# SYNOPSIS
 man/runc-events.8.md:# SYNOPSIS
 man/runc-exec.8.md:# SYNOPSIS
 man/runc-kill.8.md:# SYNOPSIS
 man/runc-list.8.md:# SYNOPSIS
 man/runc-pause.8.md:# SYNOPSIS
 man/runc-restore.8.md:# SYNOPSIS
 man/runc-resume.8.md:# SYNOPSIS
 man/runc-spec.8.md:# SYNOPSIS
 man/runc-start.8.md:# SYNOPSIS
 man/runc-state.8.md:# SYNOPSIS
 man/runc-update.8.md:# SYNOPSIS
 man/runc.8.md:# SYNOPSIS
 #

Reason2:
 Most linux commands are using word of "SYNOPSIS"
 # man ls
 # man find
 # ...

Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-05-25 10:48:11 +08:00
Zhao Lei a0096535a6 Fix some spelling typo in manual and source
infomation -> information
transfered -> transferred

Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
2016-05-20 15:04:40 +08:00
rajasec ffd5002a18 Updating runc man page
Signed-off-by: rajasec <rajasec79@gmail.com>

Fixed the review comment

Signed-off-by: rajasec <rajasec79@gmail.com>
2016-05-12 22:43:10 +05:30
rajasec 8839f9f70b Adding kernel mem tcp for update command
Signed-off-by: rajasec <rajasec79@gmail.com>

Adding kernel mem tcp for update command

Signed-off-by: rajasec <rajasec79@gmail.com>

Fixing update.bats to reduce the TCP value

Signed-off-by: rajasec <rajasec79@gmail.com>

Updated the kernelTCP in bats as per json

Signed-off-by: rajasec <rajasec79@gmail.com>

Fixed some minor issue in bats file

Signed-off-by: rajasec <rajasec79@gmail.com>

Rounded off to right bytes for kernel TCP

Signed-off-by: rajasec <rajasec79@gmail.com>

Updating man file for update command

Signed-off-by: rajasec <rajasec79@gmail.com>
2016-05-10 14:11:36 +05:30
Qiang Huang e75465b1a3 Add man page and fix typo for update command
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2016-05-09 19:04:25 +08:00
Mrunal Patel 8075a9ee6f Change OCF to OCI in help string and man page.
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2016-05-03 16:05:20 -07:00
Qiang Huang 8b0d5831b8 Add infomation about ocitools in runc spec
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2016-04-21 12:57:26 +08:00
Michael Crosby 616ad448e1 Merge pull request #751 from mrunalp/list_quiet
Add -q to list to print only container IDs
2016-04-19 16:16:09 -07:00
Mrunal Patel 852d20b0c6 Add -q to list to print only container IDs
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2016-04-14 16:19:33 -07:00
rajasec 1e070e51d9 updating man page for start option
Signed-off-by: rajasec <rajasec79@gmail.com>
2016-04-13 19:08:58 +05:30
Michael Crosby 24950964ec Merge pull request #667 from mrunalp/systemd_cgroups
Add support for enabling systemd cgroups
2016-03-23 16:14:03 -07:00
Mrunal Patel 0e4170849f Update man page for runc
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2016-03-22 17:09:51 -07:00
Mike Brown fdf9ef46b2 adds detail to runc start and spec help text
Signed-off-by: Mike Brown <brownwm@us.ibm.com>
2016-03-18 13:54:06 -05:00
Mrunal Patel 208870ce18 Add README.md for generating man pages
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2016-03-04 11:14:12 -08:00
Mrunal Patel d8482f3577 Add script to generate man pages from markdown
This is copied from docker

Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2016-03-04 11:14:12 -08:00
Mrunal Patel dffb1d232b Add man pages in markdown format
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2016-03-04 11:14:02 -08:00