Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type PlatformInfo ¶
type PlatformInfo struct { Name PlatformType `json:"name"` K8SVersion string `json:"k8sVersion"` OS string `json:"os"` }
func GetPlatformInfo ¶
func GetPlatformInfo(cfg *rest.Config) (PlatformInfo, error)
GetPlatformInfo examines the Kubernetes-based environment and determines the running platform, version, & OS. Accepts <nil> or instantiated 'cfg' rest config parameter.
Result: PlatformInfo{ Name: OpenShift, K8SVersion: 1.13+, OS: linux/amd64 }
func (PlatformInfo) IsOpenShift ¶
func (info PlatformInfo) IsOpenShift() bool
func (PlatformInfo) String ¶
func (info PlatformInfo) String() string
type PlatformType ¶
type PlatformType string
const ( OpenShift PlatformType = "OpenShift" Kubernetes PlatformType = "Kubernetes" )
Click to show internal directories.
Click to hide internal directories.