package
2.0.0-alpha.3
Repository: https://github.com/k0sproject/rig.git
Documentation: pkg.go.dev

# Functions

Doas is a DecorateFunc that will wrap the given command in a doas call.
NewProvider returns a new sudo repository.
NewSudoService creates a new instance of SudoService with the provided SudoProvider and runner.
Noop is a DecorateFunc that will return the given command unmodified.
RegisterDoas registers a doas DecorateFunc with the given repository.
RegisterSudo registers a sudo DecorateFunc with the given repository.
RegisterUID0Noop registers a noop DecorateFunc with the given repository which can be used when the user is root.
RegisterWindowsNoop registers a noop DecorateFunc with the given repository if the user is root.
Sudo is a DecorateFunc that will wrap the given command in a sudo call.

# Variables

DefaultProvider is the default sudo repository.
ErrNoSudo is returned when no supported sudo method is found.

# Structs

Service provides a unified interface to interact with different package managers.

# Interfaces

SudoProvider returns a new cmd.Runner with elevated privileges based on the given runner.