Update to avoid deprecated types
Replace our use of the github.com/opencontainers/runc/libcontainer/devices.Permissions type with the github.com/opencontainers/cgroups/devices/config.Permissions type, which the former is now an alias for. Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
This commit is contained in:
parent
7ce7072f25
commit
9ac03e6bf9
2
go.mod
2
go.mod
|
@ -23,6 +23,7 @@ require (
|
|||
github.com/moby/buildkit v0.21.0
|
||||
github.com/moby/sys/capability v0.4.0
|
||||
github.com/moby/sys/userns v0.1.0
|
||||
github.com/opencontainers/cgroups v0.0.1
|
||||
github.com/opencontainers/go-digest v1.0.0
|
||||
github.com/opencontainers/image-spec v1.1.1
|
||||
github.com/opencontainers/runc v1.3.0
|
||||
|
@ -119,7 +120,6 @@ require (
|
|||
github.com/modern-go/reflect2 v1.0.2 // indirect
|
||||
github.com/morikuni/aec v1.0.0 // indirect
|
||||
github.com/oklog/ulid v1.3.1 // indirect
|
||||
github.com/opencontainers/cgroups v0.0.1 // indirect
|
||||
github.com/ostreedev/ostree-go v0.0.0-20210805093236-719684c64e4f // indirect
|
||||
github.com/pkg/errors v0.9.1 // indirect
|
||||
github.com/planetscale/vtprotobuf v0.6.1-0.20240319094008-0393e58bdf10 // indirect
|
||||
|
|
|
@ -8,6 +8,7 @@ import (
|
|||
"path/filepath"
|
||||
|
||||
"github.com/containers/buildah/define"
|
||||
"github.com/opencontainers/cgroups/devices/config"
|
||||
"github.com/opencontainers/runc/libcontainer/devices"
|
||||
)
|
||||
|
||||
|
@ -47,7 +48,7 @@ func DeviceFromPath(device string) (define.ContainerDevices, error) {
|
|||
}
|
||||
for _, d := range srcDevices {
|
||||
d.Path = filepath.Join(dst, filepath.Base(d.Path))
|
||||
d.Permissions = devices.Permissions(permissions)
|
||||
d.Permissions = config.Permissions(permissions)
|
||||
device := define.BuildahDevice{Device: *d, Source: src, Destination: dst}
|
||||
devs = append(devs, device)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue