Skip to content

Commit

Permalink
Merge pull request #2110 from Ace-Tang/doc_runtime
Browse files Browse the repository at this point in the history
docs: add runtime format in config doc
  • Loading branch information
HusterWan authored Aug 20, 2018
2 parents 6732c78 + 803fba3 commit 8eb612e
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 1 deletion.
16 changes: 15 additions & 1 deletion docs/features/pouch_with_kata.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,20 @@ You might need to modify this file, make sure that all binaries have right path

With all the steps finish, you can play with kata container.

1. add kata-runtime into config file, restart pouchd, ensure that pouchd know the specified runtime.

```
{
"add-runtime": {
"kata-runtime": {
"path": "/usr/local/bin/kata-runtime"
}
}
}
```

2. start kata container.

```shell
$ pouch run -d --runtime=kata-runtime 8ac48589692a top
00d1f38250fc76b5e66e7fa05a41d342d1b48202d24e2dbf06b20a113b2a008c
Expand All @@ -73,7 +87,7 @@ Name ID Status Created Image
00d1f3 00d1f3 Up 5 seconds 7 seconds ago docker.io/library/busybox:latest kata-runtime
```

Enter into the kata container.
3. enter into the kata container.

```shell
$ pouch exec -it 00d1f3 sh
Expand Down
12 changes: 12 additions & 0 deletions docs/features/pouch_with_runV.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,18 @@ With runv related tools installed, we need to start pouchd. Then we can create h

We can create hypervisor-based container by adding a flag `--runtime` in create command. And we can also use `pouch ps` to list containers including hypervisor-based containers whose runtime type is `runv` and runc-based containerd whose runtime type is `runc`.

First, add runv into config file, restart pouchd, ensure that pouchd know the specified runtime.

```
{
"add-runtime": {
"runv": {
"path": "/usr/local/bin/runv"
}
}
}
```

``` shell
$ pouch create --name hypervisor --runtime runv docker.io/library/busybox:latest
container ID: 95c8d52154515e58ab267f3c33ef74ff84c901ad77ab18ee6428a1ffac12400d, name: hypervisor
Expand Down
17 changes: 17 additions & 0 deletions docs/user/config_file.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,23 @@ value of `--config-file`.
* We allow users set slice or array type of flag simultaneously from command
and config file line,and merge them.

### Runtime format

If user want to add more runtime into pouchd, add like:

```
{
"add-runtime": {
"runc": {
"path": "/usr/local/bin/runc",
"runtimeArgs": [
"--debug"
]
}
}
}
```

### Steps to configure config file

1. Install PouchContainer, you can find detail steps in [PouchContainer install](https://github.com/alibaba/pouch/blob/master/INSTALLATION.md).
Expand Down

0 comments on commit 8eb612e

Please sign in to comment.