drenv

package
v0.0.0-...-9dd3fcf Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadKubeConfigFor

func LoadKubeConfigFor(context string, path string) (*api.Config, error)

LoadKubeConfigFor loads config for specified context form minikube generated kubeconfig file with multiple contexts.

The config refers to minikube certificates and keys on the same host, so it cannot be used from another host.

Like `kubectl config view --minify --context context`. Based on kubectl/pkg/cmd/config/view.go

Types

type Environment

type Environment struct {
	Name  string     `json:"name"`
	Ramen *RamenInfo `json:"ramen"`
}

Environment is ramen testing environment file.

func Load

func Load(path string, options Options) (*Environment, error)

type Options

type Options struct {
	NamePrefix string
}

type RamenInfo

type RamenInfo struct {
	Hub      string         `json:"hub"`
	Clusters []string       `json:"clusters"`
	Topology api.DRTopology `json:"topology"`
}

RamenInfo describes the ramen environment. The hub and clusters names are context names stored in the home kubeconfig (~/.kube/config).

Jump to

Keyboard shortcuts

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