Documentation
¶
Index ¶
- func ContainCluster(clusterProvider, clusterName string, lcClusterRefs []common.Cluster) bool
- func ConvertType(in, out interface{}) error
- func EnsureDirectory(f string) error
- func ExtractTarBall(r io.Reader) (string, error)
- func HasDuplication(list []string) bool
- func HasIntersection(list1 []string, list2 []string) bool
- func ListDifference(list1 []string, list2 []string) []string
- func MapKeys(m map[string]interface{}) []string
- func StructToMap(s interface{}) (map[string]interface{}, error)
- type ListYamlStruct
- type YamlStruct
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContainCluster ¶
func ConvertType ¶
func ConvertType(in, out interface{}) error
func EnsureDirectory ¶
EnsureDirectory makes sure that the directories specified in the path exist If not, it will create them, if possible.
func ExtractTarBall ¶
ExtractTarBall provides functionality to extract a tar.gz file into a temporary location for later use. It returns the path to the new location
func HasDuplication ¶
func HasIntersection ¶
func ListDifference ¶
func StructToMap ¶
Types ¶
type ListYamlStruct ¶
type ListYamlStruct struct { APIVersion string `yaml:"apiVersion,omitempty"` Kind string `yaml:"kind,omitempty"` // contains filtered or unexported fields }
ListYamlStruct is applied when the kind is list
type YamlStruct ¶
type YamlStruct struct { APIVersion string `yaml:"apiVersion,omitempty"` Kind string `yaml:"kind,omitempty"` Metadata struct { Name string `yaml:"name,omitempty"` Namespace string `yaml:"namespace,omitempty"` Labels struct { RouterDeisIoRoutable string `yaml:"router.deis.io/routable,omitempty"` } `yaml:"labels"` Annotations struct { RouterDeisIoDomains string `yaml:"router.deis.io/domains,omitempty"` } `yaml:"annotations,omitempty"` } `yaml:"metadata,omitempty"` Spec struct { Type string `yaml:"type,omitempty"` Selector struct { App string `yaml:"app,omitempty"` } `yaml:"selector,omitempty"` Ports []struct { Name string `yaml:"name,omitempty"` Port int `yaml:"port,omitempty"` NodePort int `yaml:"nodePort,omitempty"` } `yaml:"ports"` } `yaml:"spec"` }
YamlStruct represents normal parameters in a manifest file. Over the course of time, Pls add more parameters as and when you require.
func ExtractYamlParameters ¶
func ExtractYamlParameters(f string) (YamlStruct, error)
ExtractYamlParameters is a method which takes in the abolute path of a manifest file and returns a struct accordingly
Click to show internal directories.
Click to hide internal directories.