devchar

package
v1.17.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 4, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewCommand

func NewCommand(logger logger.Interface) *cli.Command

NewCommand constructs a command sub-command with the specified logger

Types

type Creator

type Creator interface {
	CreateLinks() error
}

Creator is an interface for creating symlinks to /dev/nv* devices in /dev/char.

func NewSymlinkCreator

func NewSymlinkCreator(opts ...Option) (Creator, error)

NewSymlinkCreator creates a new linkCreator.

type Option

type Option func(*linkCreator)

Option is a functional option for configuring the linkCreator.

func WithCreateAll

func WithCreateAll(createAll bool) Option

WithCreateAll sets the createAll flag for the linkCreator.

func WithCreateDeviceNodes added in v1.13.2

func WithCreateDeviceNodes(createDeviceNodes bool) Option

WithCreateDeviceNodes sets the createDeviceNodes flag for the linkCreator.

func WithDevCharPath

func WithDevCharPath(path string) Option

WithDevCharPath sets the path at which the symlinks will be created.

func WithDevRoot added in v1.13.3

func WithDevRoot(root string) Option

WithDevRoot sets the root path for the /dev directory.

func WithDriverRoot

func WithDriverRoot(root string) Option

WithDriverRoot sets the driver root path. This is the path in which kernel modules must be loaded.

func WithDryRun

func WithDryRun(dryRun bool) Option

WithDryRun sets the dry run flag.

func WithLoadKernelModules added in v1.13.2

func WithLoadKernelModules(loadKernelModules bool) Option

WithLoadKernelModules sets the loadKernelModules flag for the linkCreator.

func WithLogger

func WithLogger(logger logger.Interface) Option

WithLogger sets the logger.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL