utils

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2023 License: Apache-2.0 Imports: 16 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DecodeRecoveryToken

func DecodeRecoveryToken(recoverytoken string) []string

func EncodeRecoveryToken

func EncodeRecoveryToken(data ...string) string

func Flavor

func Flavor() string

func GetInterfaceIP

func GetInterfaceIP(in string) string

func IsOpenRCBased

func IsOpenRCBased() bool

func K3sBin

func K3sBin() string

func ListOutput

func ListOutput(rels []string, output string) []string

func OSRelease

func OSRelease(key string) (string, error)

func OnSignal

func OnSignal(fn func(), sig ...os.Signal)

func PowerOFF

func PowerOFF()

func PrintBanner

func PrintBanner(d []byte)

func Prompt

func Prompt(t string) (string, error)

func RandStringRunes

func RandStringRunes(n int) string

func Reboot

func Reboot()

func SH

func SH(c string) (string, error)

func SHInDir added in v1.4.0

func SHInDir(c, dir string) (string, error)

func SetEnv added in v1.1.4

func SetEnv(env []string)

func Shell

func Shell() *exec.Cmd

func ShellSTDIN

func ShellSTDIN(s, c string) (string, error)

func Version

func Version() string

func WriteEnv

func WriteEnv(envFile string, config map[string]string) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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