utils

package
v3.0.4 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2025 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var HeaderLines = 14
View Source
var Logger *logrus.Logger
View Source
var ValidColors = map[string]bool{
	"red":    true,
	"green":  true,
	"orange": true,
}
View Source
var ValidMetrics = map[string]bool{
	"memory": true,
	"disk":   true,
	"cpu":    true,
}
View Source
var ValidSorts = map[string]bool{
	"name":     true,
	"node":     true,
	"free":     true,
	"usage":    true,
	"color":    true,
	"capacity": true,
	"max":      true,
}
View Source
var Version = "v3.0.4"

Version holds the current version of KubeNodeUsage

Functions

func InitLogger

func InitLogger()

func IsValidColor

func IsValidColor(input string) bool

func IsValidMetric

func IsValidMetric(input string) bool

func IsValidSort

func IsValidSort(input string) bool

func PrintValidColors

func PrintValidColors() []string

func PrintValidMetrics

func PrintValidMetrics() string

func PrintValidSorts

func PrintValidSorts() string

Types

type Inputs

type Inputs struct {
	HelpFlag       bool
	ReverseFlag    bool
	Debug          bool
	SortBy         string
	FilterNodes    string
	FilterColor    string
	FilterLabel    string
	Metrics        string
	LabelToDisplay string
	LabelAlias     string
	NoInfo         bool
	Pods           bool
	Help           bool
}

Jump to

Keyboard shortcuts

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