mirror of
https://github.com/containers/podman.git
synced 2025-09-28 01:04:28 +08:00
cgroupsns was not following containers.conf
Implement ParseCgroupsNamespace to handle defaults. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
19
vendor/github.com/containers/buildah/pkg/parse/parse.go
generated
vendored
19
vendor/github.com/containers/buildah/pkg/parse/parse.go
generated
vendored
@ -927,25 +927,6 @@ func IsolationOption(isolation string) (buildah.Isolation, error) {
|
||||
return defaultIsolation()
|
||||
}
|
||||
|
||||
// ScrubServer removes 'http://' or 'https://' from the front of the
|
||||
// server/registry string if either is there. This will be mostly used
|
||||
// for user input from 'buildah login' and 'buildah logout'.
|
||||
func ScrubServer(server string) string {
|
||||
server = strings.TrimPrefix(server, "https://")
|
||||
return strings.TrimPrefix(server, "http://")
|
||||
}
|
||||
|
||||
// RegistryFromFullName gets the registry from the input. If the input is of the form
|
||||
// quay.io/myuser/myimage, it will parse it and just return quay.io
|
||||
// It also returns true if a full image name was given
|
||||
func RegistryFromFullName(input string) string {
|
||||
split := strings.Split(input, "/")
|
||||
if len(split) > 1 {
|
||||
return split[0]
|
||||
}
|
||||
return split[0]
|
||||
}
|
||||
|
||||
// Device parses device mapping string to a src, dest & permissions string
|
||||
// Valid values for device looklike:
|
||||
// '/dev/sdc"
|
||||
|
Reference in New Issue
Block a user