types
import "github.com/ice-bergtech/kr8/pkg/types"
Package types contains shared types used across kr8+ packages.
Index
- type CmdJsonnetOptions
- type Kr8Cluster
- type Kr8Error
- func (e Kr8Error) Error() string
- type Kr8Opts
- type VMConfig
type CmdJsonnetOptions
Options for running the jsonnet command. Used by a few packages and commands.
type CmdJsonnetOptions struct {
Prune bool
Cluster string
ClusterParams string
Component string
Format string
Color bool
}
type Kr8Cluster
An object that stores variables that can be referenced by components.
type Kr8Cluster struct {
Name string `json:"name"`
Path string `json:"-"`
}
type Kr8Error
Shared kr8+ error struct.
type Kr8Error struct {
// Message to show the user.
Message string
// Value to include with message
Value interface{}
}
func (Kr8Error) Error
func (e Kr8Error) Error() string
Error implements error.
type Kr8Opts
Options that configure where kr8+ looks for files.
type Kr8Opts struct {
// Base directory of kr8+ configuration
BaseDir string
// Directory where component definitions are stored
ComponentDir string
// Directory where cluster configurations are stored
ClusterDir string
}
type VMConfig
VMConfig describes configuration to initialize the Jsonnet VM with.
type VMConfig struct {
// JPaths is a list of paths to search for Jsonnet libraries (libsonnet files)
JPaths []string `json:"jpath" yaml:"jpath"`
// ExtVars is a list of external variables to pass to Jsonnet VM
ExtVars []string `json:"ext_str_file" yaml:"ext_str_files"`
// base directory for the project
BaseDir string `json:"base_dir" yaml:"base_dir"`
}