github.com/kaisenlinux/docker.io@v0.0.0-20230510090727-ea55db55fac7/engine/oci/devices_unsupported.go (about)

     1  //go:build !linux
     2  // +build !linux
     3  
     4  package oci // import "github.com/docker/docker/oci"
     5  
     6  import (
     7  	"errors"
     8  
     9  	"github.com/opencontainers/runc/libcontainer/configs"
    10  	specs "github.com/opencontainers/runtime-spec/specs-go"
    11  )
    12  
    13  // Device transforms a libcontainer configs.Device to a specs.Device object.
    14  // Not implemented
    15  func Device(d *configs.Device) specs.LinuxDevice { return specs.LinuxDevice{} }
    16  
    17  // DevicesFromPath computes a list of devices and device permissions from paths (pathOnHost and pathInContainer) and cgroup permissions.
    18  // Not implemented
    19  func DevicesFromPath(pathOnHost, pathInContainer, cgroupPermissions string) (devs []specs.LinuxDevice, devPermissions []specs.LinuxDeviceCgroup, err error) {
    20  	return nil, nil, errors.New("oci/devices: unsupported platform")
    21  }