keychain

package
v0.6.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDockerconfigKeychain

func NewDockerconfigKeychain(ctx context.Context) func(host string) (string, string, error)

func NewKubeconfigKeychain

func NewKubeconfigKeychain(ctx context.Context, opts ...KubeconfigOption) func(string) (string, string, error)

NewKubeconfigKeychain provides a keychain which can sync its contents with kubernetes API server by fetching all `kubernetes.io/dockerconfigjson` secrets in the cluster with provided kubeconfig. It's OK that config provides kubeconfig path but the file doesn't exist at that moment. In this case, this keychain keeps on trying to read the specified path periodically and when the file is actually provided, this keychain tries to access API server using the file. This is useful for some environments (e.g. single node cluster with containerized apiserver) where stargz snapshotter needs to start before everything, including booting containerd/kubelet/apiserver and configuring users/roles. TODO: support update of kubeconfig file

Types

type KubeconfigOption

type KubeconfigOption func(*options)

func WithKubeconfigPath

func WithKubeconfigPath(path string) KubeconfigOption

Jump to

Keyboard shortcuts

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