Merge pull request #1356 from Random-Liu/revert-#1349
Fix privileged support
This commit is contained in:
commit
e68cc95fe4
@ -8,8 +8,9 @@ environment:
|
||||
GOPATH: C:\gopath
|
||||
PATH: C:\go\bin;C:\tools\mingw64\bin;$(PATH)
|
||||
CGO_ENABLED: 1
|
||||
GO111MODULE: off
|
||||
matrix:
|
||||
- GO_VERSION: 1.12.9
|
||||
- GO_VERSION: 1.13.4
|
||||
|
||||
install:
|
||||
# Install Mingw
|
||||
|
@ -3,7 +3,7 @@ git:
|
||||
|
||||
language: go
|
||||
go:
|
||||
- 1.12.x
|
||||
- 1.13.4
|
||||
- tip
|
||||
|
||||
|
||||
@ -13,6 +13,9 @@ matrix:
|
||||
|
||||
sudo: required
|
||||
|
||||
env:
|
||||
- GO111MODULE=off
|
||||
|
||||
services:
|
||||
- docker
|
||||
|
||||
|
@ -170,7 +170,7 @@ func (c *criService) containerSpec(id string, sandboxID string, sandboxPid uint3
|
||||
}
|
||||
specOpts = append(specOpts, oci.WithPrivileged)
|
||||
if !ociRuntime.PrivilegedWithoutHostDevices {
|
||||
specOpts = append(specOpts, oci.WithHostDevices)
|
||||
specOpts = append(specOpts, oci.WithHostDevices, oci.WithAllDevicesAllowed)
|
||||
}
|
||||
} else { // not privileged
|
||||
specOpts = append(specOpts, customopts.WithDevices(c.os, config), customopts.WithCapabilities(securityContext))
|
||||
|
Loading…
Reference in New Issue
Block a user