mirror of
https://github.com/opencontainers/runc.git
synced 2025-10-30 02:31:54 +08:00
This removes libcontainer/cgroups packages and starts
using those from github.com/opencontainers/cgroups repo.
Mostly generated by:
git rm -f libcontainer/cgroups
find . -type f -name "*.go" -exec sed -i \
's|github.com/opencontainers/runc/libcontainer/cgroups|github.com/opencontainers/cgroups|g' \
{} +
go get github.com/opencontainers/cgroups@v0.0.1
make vendor
gofumpt -w .
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
24 lines
472 B
Go
24 lines
472 B
Go
package integration
|
|
|
|
import (
|
|
"os"
|
|
"testing"
|
|
|
|
"github.com/opencontainers/runc/libcontainer"
|
|
//nolint:revive // Enable cgroup manager to manage devices
|
|
_ "github.com/opencontainers/cgroups/devices"
|
|
_ "github.com/opencontainers/runc/libcontainer/nsenter"
|
|
)
|
|
|
|
// Same as ../../init.go but for libcontainer/integration.
|
|
func init() {
|
|
if len(os.Args) > 1 && os.Args[1] == "init" {
|
|
libcontainer.Init()
|
|
}
|
|
}
|
|
|
|
func TestMain(m *testing.M) {
|
|
ret := m.Run()
|
|
os.Exit(ret)
|
|
}
|