Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type K3sContainer ¶
type K3sContainer struct {
testcontainers.Container
}
K3sContainer represents the K3s container type used in the module
func Prepare ¶
func Prepare(ctx context.Context, opts ...testcontainers.ContainerCustomizer) (*K3sContainer, error)
Prepare creates an instance of the K3s container type
func (*K3sContainer) GetKubeConfig ¶
func (c *K3sContainer) GetKubeConfig(ctx context.Context) ([]byte, error)
GetKubeConfig returns the modified kubeconfig with server url
type KubeConfigValue ¶
type KubeConfigValue struct { APIVersion string `yaml:"apiVersion"` Kind string `yaml:"kind"` Clusters []KubeconfigNamedCluster `yaml:"clusters"` Users []KubeconfigUser `yaml:"users"` Contexts []KubeconfigNamedContext `yaml:"contexts"` CurrentContext string `yaml:"current-context"` Preferences struct{} `yaml:"preferences"` }
KubeConfigValue is a struct used to create a kubectl configuration YAML file.
type KubeconfigAuthProvider ¶
type KubeconfigAuthProvider struct { Name string `yaml:"name"` Config map[string]string `yaml:"config"` }
KubeconfigAuthProvider is a struct used to create a kubectl authentication provider
type KubeconfigCluster ¶
type KubeconfigCluster struct { Server string `yaml:"server"` CertificateAuthorityData string `yaml:"certificate-authority-data"` CertificateAuthority string `yaml:"certificate-authority"` }
KubeconfigCluster is a struct used to create a kubectl configuration YAML file
type KubeconfigContext ¶
type KubeconfigContext struct { Cluster string `yaml:"cluster"` Namespace string `yaml:"namespace,omitempty"` User string `yaml:"user"` }
KubeconfigContext is a struct used to create a kubectl configuration YAML file
type KubeconfigNamedCluster ¶
type KubeconfigNamedCluster struct { Name string `yaml:"name"` Cluster KubeconfigCluster `yaml:"cluster"` }
KubeconfigNamedCluster is a struct used to create a kubectl configuration YAML file
type KubeconfigNamedContext ¶
type KubeconfigNamedContext struct { Name string `yaml:"name"` Context KubeconfigContext `yaml:"context"` }
KubeconfigNamedContext is a struct used to create a kubectl configuration YAML file
type KubeconfigUser ¶
type KubeconfigUser struct { Name string `yaml:"name"` User KubeconfigUserKeyPair `yaml:"user"` }
KubeconfigUser is a struct used to create a kubectl configuration YAML file
type KubeconfigUserKeyPair ¶
type KubeconfigUserKeyPair struct { ClientCertificateData string `yaml:"client-certificate-data"` ClientKeyData string `yaml:"client-key-data"` AuthProvider KubeconfigAuthProvider `yaml:"auth-provider,omitempty"` }
KubeconfigUserKeyPair is a struct used to create a kubectl configuration YAML file