Skip to content

Commit 1b36f79

Browse files
committed
devices: add github.com/moby/sys/devices package
This is migrated from runc's libcontainer/devices, as this package has only ever really been used outside of runc to generate device configurations, so it makes more sense for it to live in github.com/moby/sys. With regards to the go.mod used, github.com/opencontainers/cgroups requires Go 1.24, but aside from that all of these requirements are as minimal as possible. Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
1 parent 730b894 commit 1b36f79

3 files changed

Lines changed: 13 additions & 1 deletion

File tree

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
PACKAGES ?= atomicwriter capability mountinfo mount reexec sequential signal symlink user userns
1+
PACKAGES ?= atomicwriter capability devices mountinfo mount reexec sequential signal symlink user userns
22
CROSS ?= linux/arm linux/arm64 linux/ppc64le linux/s390x \
33
freebsd/amd64 openbsd/amd64 darwin/amd64 darwin/arm64 windows/amd64
44
SUDO ?= sudo -n

devices/go.mod

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
module github.com/moby/sys/devices
2+
3+
go 1.24
4+
5+
require (
6+
github.com/opencontainers/cgroups v0.0.6
7+
golang.org/x/sys v0.30.0
8+
)

devices/go.sum

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
github.com/opencontainers/cgroups v0.0.6 h1:tfZFWTIIGaUUFImTyuTg+Mr5x8XRiSdZESgEBW7UxuI=
2+
github.com/opencontainers/cgroups v0.0.6/go.mod h1:oWVzJsKK0gG9SCRBfTpnn16WcGEqDI8PAcpMGbqWxcs=
3+
golang.org/x/sys v0.30.0 h1:QjkSwP/36a20jFYWkSue1YwXzLmsV5Gfq7Eiy72C1uc=
4+
golang.org/x/sys v0.30.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=

0 commit comments

Comments
 (0)