Skip to content

Commit

Permalink
create: skip resources validation with cgroup v2
Browse files Browse the repository at this point in the history
skip resources validation when cgroup v2 is detected, as we don't
support it yet.

Signed-off-by: Giuseppe Scrivano <[email protected]>
  • Loading branch information
giuseppe committed May 13, 2019
1 parent 8e88461 commit 42e65c5
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions cmd/podman/shared/create_cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"github.com/containers/libpod/cmd/podman/shared/parse"
cc "github.com/containers/libpod/pkg/spec"
"github.com/containers/libpod/pkg/sysinfo"
"github.com/containers/libpod/pkg/util"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
)
Expand Down Expand Up @@ -76,6 +77,12 @@ func addWarning(warnings []string, msg string) []string {

func verifyContainerResources(config *cc.CreateConfig, update bool) ([]string, error) {
warnings := []string{}

cgroup2, err := util.IsCgroup2UnifiedMode()
if err != nil || cgroup2 {
return warnings, err
}

sysInfo := sysinfo.New(true)

// memory subsystem checks and adjustments
Expand Down

0 comments on commit 42e65c5

Please sign in to comment.