summaryrefslogtreecommitdiff
path: root/libpod
diff options
context:
space:
mode:
authorValentin Rothberg <rothberg@redhat.com>2020-02-12 10:47:48 +0100
committerValentin Rothberg <rothberg@redhat.com>2020-02-14 12:00:45 +0100
commit156ce5cd7d6f0f1514d263a74ffe3dd42f7c7caf (patch)
treebb6e38aa54df2158e5cf8a5d87c8558ef833c424 /libpod
parent0c060dace19710716ff8f3a65865a295312d9d94 (diff)
downloadpodman-156ce5cd7d6f0f1514d263a74ffe3dd42f7c7caf.tar.gz
podman-156ce5cd7d6f0f1514d263a74ffe3dd42f7c7caf.tar.bz2
podman-156ce5cd7d6f0f1514d263a74ffe3dd42f7c7caf.zip
add pkg/capabilities
Add pkg/capabibilities to deal with capabilities. The code has been copied from Docker (and attributed with the copyright) but changed significantly to only do what we really need. The code has also been simplified and will perform better due to removed redundancy. Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
Diffstat (limited to 'libpod')
-rw-r--r--libpod/container_api.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/libpod/container_api.go b/libpod/container_api.go
index d74a14f15..d612341bc 100644
--- a/libpod/container_api.go
+++ b/libpod/container_api.go
@@ -11,8 +11,8 @@ import (
"github.com/containers/libpod/libpod/define"
"github.com/containers/libpod/libpod/events"
+ "github.com/containers/libpod/pkg/capabilities"
"github.com/containers/storage/pkg/stringid"
- "github.com/docker/docker/oci/caps"
"github.com/opentracing/opentracing-go"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
@@ -237,7 +237,7 @@ func (c *Container) Exec(tty, privileged bool, env map[string]string, cmd []stri
}
if privileged || c.config.Privileged {
- capList = caps.GetAllCapabilities()
+ capList = capabilities.AllCapabilities()
}
// Generate exec session ID