kubernetes

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2019 License: MIT Imports: 31 Imported by: 0

Documentation

Index

Constants

View Source
const (
	GlobalCarbonNamespace = "carbon-data"
)

Variables

View Source
var CurrentNamespace string

Functions

func CheckCarbonNamespace

func CheckCarbonNamespace(ns string) (bool, error)

func CreateGlobalCarbonNamespace

func CreateGlobalCarbonNamespace() error

func Delete

func Delete(manifest, ns string) error

func GetAllNamespaces

func GetAllNamespaces() (*apicorev1.NamespaceList, error)

func GetAllResources

func GetAllResources() ([]string, error)

func GetConfigMapHandler

func GetConfigMapHandler(namespace string) (typedcorev1.ConfigMapInterface, error)

func GetNamespaceHandler

func GetNamespaceHandler() (typedcorev1.NamespaceInterface, error)

func GetSecretHandler

func GetSecretHandler(namespace string) (typedcorev1.SecretInterface, error)

func KubeConfig

func KubeConfig() (*restclient.Config, error)

func ReadTemplates

func ReadTemplates(cfg *pkgcfg.CarbonConfig) ([]byte, error)

func SetNamespace

func SetNamespace(cliNS string) error

Types

type DepVars

type DepVars struct {
	Pkg DepVarsPkg
	Var map[string]string
}

type DepVarsPkg

type DepVarsPkg struct {
	DockerName string
	DockerTag  string
	Name       string
	Version    string
}

type KubeInstall

type KubeInstall struct {
	BuiltManifest []byte
	RawManifest   []byte
	Variables     DepVars
}

func NewKubeInstall

func NewKubeInstall(meta *pkgmeta.PackageConfig, dname string, dtag string) (*KubeInstall, error)

func (*KubeInstall) Apply

func (self *KubeInstall) Apply(defPWL bool) error

func (*KubeInstall) Build

func (self *KubeInstall) Build() error

func (*KubeInstall) ProcessPatches

func (self *KubeInstall) ProcessPatches(data []byte) error

func (*KubeInstall) SetAppLabel

func (self *KubeInstall) SetAppLabel() error

func (*KubeInstall) UpdateVars

func (self *KubeInstall) UpdateVars(vars map[string]string)

func (*KubeInstall) VerifyAll

func (self *KubeInstall) VerifyAll(path string) error

func (*KubeInstall) VerifyTpl

func (self *KubeInstall) VerifyTpl(path string) error

type Patcher

type Patcher struct {
	Filters map[string]string `json:"filters"`
	Type    string            `json:"type"`
	Patch   json.RawMessage   `json:"patch"`
}

func (*Patcher) Apply

func (self *Patcher) Apply(original []byte) ([]byte, error)

func (*Patcher) MatchObj

func (self *Patcher) MatchObj(data []byte) (bool, error)

Jump to

Keyboard shortcuts

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