util

package
v0.2.11 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Compress

func Compress(s string) (string, error)

Compress gzips a string and base64 encodes it

func GetAccountFromNamespace

func GetAccountFromNamespace(namespace metav1.Object) string

GetAccountFromNamespace retrieves the account from a namespace meta

func IsNamespaceInitializing

func IsNamespaceInitializing(namespace metav1.Object) bool

IsNamespaceInitializing checks if the given namespace is initializing

func Output

func Output(command string, args ...string) (string, error)

Output runs a specified command and pretty prints an possible error

func Run

func Run(command string, args ...string) error

Run runs a specified command and pretty prints an possible error

func StringsEqual

func StringsEqual(a []string, b []string) bool

StringsEqual checks if two string arrays are equal

func Uncompress

func Uncompress(s string) (string, error)

Uncompress uncompresses a string

Types

type LockFactory

type LockFactory interface {
	GetLock(string) sync.Locker
}

LockFactory is the interface to retrieve named locks from

func NewDefaultLockFactory

func NewDefaultLockFactory() LockFactory

NewDefaultLockFactory creates a new lock factory

Jump to

Keyboard shortcuts

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