dtest_k3s

package
v2.0.0-rc.6 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2021 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DockerRegistry

func DockerRegistry() string

DockerRegistry returns a docker registry suitable for use in tests.

func GetKubeconfig

func GetKubeconfig() string

GetKubeconfig returns the kubeconfig contents for the running k3s cluster as a string. It will return the empty string if no cluster is running.

func K3sDown

func K3sDown() string

K3sDown shuts down the k3s cluster.

func K3sUp

func K3sUp() string

K3sUp will launch if necessary and return the docker id of a container running a k3s cluster.

func Kubeconfig

func Kubeconfig() string

Kubeconfig returns a path referencing a kubeconfig file suitable for use in tests.

func RegistryDown

func RegistryDown() string

RegistryDown shutsdown the test registry.

func RegistryUp

func RegistryUp() string

RegistryUp will launch if necessary and return the docker id of a container running a docker registry.

func WithMachineLock

func WithMachineLock(body func())

WithMachineLock executes the supplied body with a guarantee that it is the only code running (via WithMachineLock) on the machine.

func WithNamedMachineLock

func WithNamedMachineLock(name string, body func())

WithNamedMachineLock executes the supplied body with a guarantee that it is the only code running (via WithMachineLock) on the machine. The name provides scope so this can be used in multiple independent ways without conflicts.

Types

This section is empty.

Jump to

Keyboard shortcuts

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