mirror of
https://github.com/vbatts/go-cgroup.git
synced 2024-11-23 17:15:39 +00:00
Merge pull request #2 from frankscholten/enhancement/sample
Updated sample in documentation
This commit is contained in:
commit
489e2f59f2
1 changed files with 18 additions and 10 deletions
|
@ -16,7 +16,13 @@ on fedora, you'll need packages: golang, libcgroup-devel
|
||||||
Sample
|
Sample
|
||||||
======
|
======
|
||||||
|
|
||||||
|
```
|
||||||
|
package main
|
||||||
|
|
||||||
|
import "github.com/vbatts/go-cgroup"
|
||||||
|
import "fmt"
|
||||||
|
|
||||||
|
func main() {
|
||||||
cgroup.Init()
|
cgroup.Init()
|
||||||
|
|
||||||
fmt.Println(cgroup.GetSubSysMountPoint("cpu"))
|
fmt.Println(cgroup.GetSubSysMountPoint("cpu"))
|
||||||
|
@ -30,6 +36,8 @@ Sample
|
||||||
fmt.Println(ctls[i])
|
fmt.Println(ctls[i])
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
Contributing
|
Contributing
|
||||||
============
|
============
|
||||||
|
|
Loading…
Reference in a new issue