Skip to content

Commit

Permalink
Add oom_score_adj to the runtime Spec.
Browse files Browse the repository at this point in the history
  • Loading branch information
vishh committed Oct 12, 2015
1 parent f81d025 commit 6486e99
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
8 changes: 8 additions & 0 deletions runtime-config-linux.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,14 @@ For example, to run a new process in an existing container without updating limi
"disableOOMKiller": false
```

#### Set oom_score_adj

More information on `oom_score_adj` available [here](https://www.kernel.org/doc/Documentation/filesystems/proc.txt).

```json
"oomScoreAdj": 0
```

#### Memory

```json
Expand Down
2 changes: 2 additions & 0 deletions runtime_config_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,8 @@ type Network struct {
type Resources struct {
// DisableOOMKiller disables the OOM killer for out of memory conditions
DisableOOMKiller bool `json:"disableOOMKiller"`
// Specify an oom_score_adj for the container. Optional.
OOMScoreAdj int `json:"oomScoreAdj"`
// Memory restriction configuration
Memory Memory `json:"memory"`
// CPU resource restriction configuration
Expand Down

0 comments on commit 6486e99

Please sign in to comment.