Skip to content

Commit 3cad3d6

Browse files
rudyflycardyok
authored andcommitted
Signed-off-by: Rudy Zhang <[email protected]>
1 parent 10ec565 commit 3cad3d6

File tree

3 files changed

+6
-9
lines changed

3 files changed

+6
-9
lines changed

daemon/mgr/container_exec.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,10 +121,9 @@ func (mgr *ContainerManager) StartExec(ctx context.Context, execid string, cfg *
121121
if execConfig.Privileged {
122122
capList := caps.GetAllCapabilities()
123123
process.Capabilities = &specs.LinuxCapabilities{
124-
Effective: capList,
125-
Bounding: capList,
126-
Permitted: capList,
127-
Inheritable: capList,
124+
Effective: capList,
125+
Bounding: capList,
126+
Permitted: capList,
128127
}
129128
} else if spec, err := mgr.getContainerSpec(c); err == nil {
130129
// NOTE: if container is created by docker and taken over by pouchd,

daemon/mgr/spec_process.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,6 @@ func setupCapabilities(ctx context.Context, hostConfig *types.HostConfig, s *spe
101101
capabilities.Effective = caplist
102102
capabilities.Bounding = caplist
103103
capabilities.Permitted = caplist
104-
capabilities.Inheritable = caplist
105104

106105
s.Process.Capabilities = capabilities
107106
return nil

oci/spec_default.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -77,10 +77,9 @@ func NewDefaultSpec() *specs.Spec {
7777

7878
s.Process = &specs.Process{
7979
Capabilities: &specs.LinuxCapabilities{
80-
Bounding: defaultCaps(),
81-
Permitted: defaultCaps(),
82-
Inheritable: defaultCaps(),
83-
Effective: defaultCaps(),
80+
Bounding: defaultCaps(),
81+
Permitted: defaultCaps(),
82+
Effective: defaultCaps(),
8483
},
8584
}
8685

0 commit comments

Comments
 (0)