util

package
v1.2.2 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2022 License: Apache-2.0 Imports: 19 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ArchAlias added in v1.2.0

func ArchAlias(arch string) string

ArchAlias returns the alias of cpu's architecture. amd64: x86_64 arm64: aarch64

func CreateDir

func CreateDir(path string) error

func GetArgs added in v1.1.0

func GetArgs(argsMap map[string]string, args []string) ([]string, map[string]string)

func GetAvailableIP

func GetAvailableIP(ipAndMask string) []string

func GetAvailableIPRange

func GetAvailableIPRange(ipStart, ipEnd string) []string

func GetLocalIP

func GetLocalIP() (string, error)

func Home

func Home() (string, error)

returns the home directory for the executing user.

func IPAddressToCIDR

func IPAddressToCIDR(ipAdress string) string

func IPMaskStringToCIDR

func IPMaskStringToCIDR(netmask string) string

func InitLogger

func InitLogger(verbose bool) *log.Logger

func IsExist

func IsExist(path string) bool

func LocalIP

func LocalIP() string

func NewClient

func NewClient(config string) (*kubernetes.Clientset, error)

func NewDynamicClient

func NewDynamicClient(config string) (*rest.Config, error)

func ParseIp

func ParseIp(ip string) []string

func RefineDockerVersion added in v1.1.0

func RefineDockerVersion(version string) (string, error)

func Render

func Render(tmpl *template.Template, variables map[string]interface{}) (string, error)

Render text template with given `variables` Render-context

Types

type Data

type Data map[string]interface{}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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