Documentation
¶
Index ¶
- Constants
- Variables
- type Config
- type Driver
- func (d *Driver) Create() error
- func (d *Driver) DriverName() string
- func (d *Driver) GetExternalIP() (string, error)
- func (d *Driver) GetIP() (string, error)
- func (d *Driver) GetSSHHostname() (string, error)
- func (d *Driver) GetSSHKeyPath() string
- func (d *Driver) GetSSHPort() (int, error)
- func (d *Driver) GetSSHUsername() string
- func (d *Driver) GetState() (state.State, error)
- func (d *Driver) GetURL() (string, error)
- func (d *Driver) Kill() error
- func (d *Driver) Remove() error
- func (d *Driver) Restart() error
- func (d *Driver) RunSSHCommandFromDriver() error
- func (d *Driver) Start() error
- func (d *Driver) Stop() error
Constants ¶
const ( // Version is the current version of kic Version = "v0.0.10" // OverlayImage is the cni plugin used for overlay image, created by kind. // CNI plugin image used for kic drivers created by kind. OverlayImage = "kindest/kindnetd:0.5.4" )
Variables ¶
var ( // BaseImage is the base image is used to spin up kic containers. it uses same base-image as kind. BaseImage = fmt.Sprintf("gcr.io/k8s-minikube/kicbase:%s@sha256:%s", Version, baseImageSHA) // BaseImageFallBack1 the fall back of BaseImage in case gcr.io is not available. stored in docker hub // same image is push to https://github.com/kicbase/stable BaseImageFallBack1 = fmt.Sprintf("kicbase/stable:%s@sha256:%s", Version, baseImageSHA) // BaseImageFallBack2 the fall back of BaseImage in case gcr.io is not available. stored in github packages https://github.com/kubernetes/minikube/packages/206071 // github packages docker does _NOT_ support pulling by sha as mentioned in the docs: // https://help.github.com/en/packages/using-github-packages-with-your-projects-ecosystem/configuring-docker-for-use-with-github-packages BaseImageFallBack2 = fmt.Sprintf("docker.pkg.github.com/kubernetes/minikube/kicbase:%s", Version) )
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { MachineName string // maps to the container name being created CPU int // Number of CPU cores assigned to the container Memory int // max memory in MB StorePath string // libmachine store path OCIBinary string // oci tool to use (docker, podman,...) ImageDigest string // image name with sha to use for the node Mounts []oci.Mount // mounts APIServerPort int // Kubernetes api server port inside the container PortMappings []oci.PortMapping // container port mappings Envs map[string]string // key,value of environment variables passed to the node KubernetesVersion string // Kubernetes version to install ContainerRuntime string // container runtime kic is running }
Config is configuration for the kic driver used by registry
type Driver ¶
type Driver struct { *drivers.BaseDriver *pkgdrivers.CommonDriver URL string NodeConfig Config OCIBinary string // docker,podman // contains filtered or unexported fields }
Driver represents a kic driver https://minikube.sigs.k8s.io/docs/reference/drivers/docker
func (*Driver) DriverName ¶
DriverName returns the name of the driver
func (*Driver) GetExternalIP ¶
GetExternalIP returns an IP which is accissble from outside
func (*Driver) GetSSHHostname ¶
GetSSHHostname returns hostname for use with ssh
func (*Driver) GetSSHKeyPath ¶
GetSSHKeyPath returns the ssh key path
func (*Driver) GetSSHPort ¶
GetSSHPort returns port for use with ssh
func (*Driver) GetSSHUsername ¶
GetSSHUsername returns the ssh username
func (*Driver) GetURL ¶
GetURL returns a Docker URL inside this host e.g. tcp://1.2.3.4:2376 more info https://github.com/docker/machine/blob/b170508bf44c3405e079e26d5fdffe35a64c6972/libmachine/provision/utils.go#L159_L175
func (*Driver) RunSSHCommandFromDriver ¶
RunSSHCommandFromDriver implements direct ssh control to the driver