Documentation ¶
Index ¶
- Constants
- Variables
- func Byte(in interface{}) []byte
- func Contains(t string, a []string) bool
- func CreateFile(p string) (*os.File, error)
- func Download(file, uri string) error
- func In[T any, C EqualChecker[T]](search C, target []T) bool
- func IsExists(s string) bool
- func IsURL(str string) bool
- func KubeInit() (err error)
- func NewCfg(ns string) (*action.Configuration, error)
- func NewHelm(ns string) (*helm.EnvSettings, error)
- func SaveInterface(file string, in interface{}) error
- func String(in interface{}) string
- type EqualChecker
Constants ¶
View Source
const ( // HTTPTimeout is a timeout for HTTP requests. HTTPTimeout = 30 * time.Second )
View Source
const (
// RootAnnoName is prefix for all kubedog annotations.
RootAnnoName = "helmwave.dev/"
)
Variables ¶
View Source
var ( // Helm is an instance of helm CLI. Helm = helm.New() // HelmRegistryClient is an instance of helm registry client. HelmRegistryClient *registry.Client )
Functions ¶
func Byte ¶ added in v0.12.0
func Byte(in interface{}) []byte
Byte marshals input to YAML and returns YAML byte slice.
func CreateFile ¶
CreateFile creates recursively basedir of file and returns created file object.
func In ¶ added in v0.20.0
func In[T any, C EqualChecker[T]](search C, target []T) bool
In returns whether `search` appears in `target` slice.
func NewCfg ¶ added in v0.12.2
func NewCfg(ns string) (*action.Configuration, error)
NewCfg creates helm internal configuration for provided namespace.
func NewHelm ¶ added in v0.12.2
func NewHelm(ns string) (*helm.EnvSettings, error)
NewHelm is a hack to create an instance of helm CLI and specifying namespace without environment variables.
func SaveInterface ¶ added in v0.12.0
SaveInterface encodes input to YAML and saves to file.
Types ¶
type EqualChecker ¶ added in v0.20.0
EqualChecker is an interface that allows to check interface for equality.
Click to show internal directories.
Click to hide internal directories.