utils

package
v0.15.5 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2021 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CurrentFuncName

func CurrentFuncName() string

CurrentFuncName returns the name of the caller of this function.

func GetOsAndSemverFromImage added in v0.15.0

func GetOsAndSemverFromImage(id string) (string, *semver.Version, error)

GetOsAndSemverFromImage parses a imageID to OS and Semver, or returns an error the last part must be the semantic version, valid ids are: ubuntu-19.04 os: ubuntu version: 19.04 ubuntu-19.04.20200408 os: ubuntu version: 19.04.20200408 ubuntu-small-19.04.20200408 os: ubuntu-small version: 19.04.20200408

func Logger

func Logger(rq *restful.Request) *zap.Logger

Logger returns the request logger from the request.

func SplitCIDR

func SplitCIDR(cidr string) (string, *int)

func StrValueDefault added in v0.9.4

func StrValueDefault(ptr *string, fallback string) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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