qemu

package
v2.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2022 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Autoscaler

type Autoscaler struct{}

Autoscaler holds the QEMU cluster-autoscaler configuration.

func (Autoscaler) Env

func (a Autoscaler) Env() []k8s.EnvVar

Env returns a list of k8s environment key-value pairs to deploy together with the k8s cluster-autoscaler.

func (Autoscaler) Name

func (a Autoscaler) Name() string

Name returns the cloud-provider name as used by k8s cluster-autoscaler.

func (Autoscaler) Secrets

func (a Autoscaler) Secrets(providerID, cloudServiceAccountURI string) (kubernetes.Secrets, error)

Secrets returns a list of secrets to deploy together with the k8s cluster-autoscaler.

func (Autoscaler) Supported

func (a Autoscaler) Supported() bool

Supported is used to determine if we support autoscaling for the cloud provider.

func (Autoscaler) VolumeMounts

func (a Autoscaler) VolumeMounts() []k8s.VolumeMount

VolumeMounts returns a list of volume mounts to deploy together with the k8s cluster-autoscaler.

func (Autoscaler) Volumes

func (a Autoscaler) Volumes() []k8s.Volume

Volumes returns a list of volumes to deploy together with the k8s cluster-autoscaler.

type CloudControllerManager

type CloudControllerManager struct{}

CloudControllerManager holds the QEMU cloud-controller-manager configuration.

func (CloudControllerManager) ConfigMaps

ConfigMaps returns a list of ConfigMaps to deploy together with the k8s cloud-controller-manager Reference: https://kubernetes.io/docs/concepts/configuration/configmap/ .

func (CloudControllerManager) Env

func (c CloudControllerManager) Env() []k8s.EnvVar

Env returns a list of k8s environment key-value pairs to deploy together with the k8s cloud-controller-manager.

func (CloudControllerManager) ExtraArgs

func (c CloudControllerManager) ExtraArgs() []string

ExtraArgs returns a list of arguments to append to the cloud-controller-manager command.

func (CloudControllerManager) Image

Image returns the container image used to provide cloud-controller-manager for the cloud-provider.

func (CloudControllerManager) Name

func (c CloudControllerManager) Name() string

Name returns the cloud-provider name as used by k8s cloud-controller-manager (k8s.gcr.io/cloud-controller-manager).

func (CloudControllerManager) Path

func (c CloudControllerManager) Path() string

Path returns the path used by cloud-controller-manager executable within the container image.

func (CloudControllerManager) PrepareInstance

func (c CloudControllerManager) PrepareInstance(instance metadata.InstanceMetadata, vpnIP string) error

PrepareInstance is called on every instance before deploying the cloud-controller-manager. Allows for cloud-provider specific hooks.

func (CloudControllerManager) Secrets

func (c CloudControllerManager) Secrets(ctx context.Context, providerID, cloudServiceAccountURI string) (kubernetes.Secrets, error)

Secrets returns a list of secrets to deploy together with the k8s cloud-controller-manager. Reference: https://kubernetes.io/docs/concepts/configuration/secret/ .

func (CloudControllerManager) Supported

func (c CloudControllerManager) Supported() bool

Supported is used to determine if cloud controller manager is implemented for this cloud provider.

func (CloudControllerManager) VolumeMounts

func (c CloudControllerManager) VolumeMounts() []k8s.VolumeMount

VolumeMounts a list of of volume mounts to deploy together with the k8s cloud-controller-manager.

func (CloudControllerManager) Volumes

func (c CloudControllerManager) Volumes() []k8s.Volume

Volumes returns a list of volumes to deploy together with the k8s cloud-controller-manager. Reference: https://kubernetes.io/docs/concepts/storage/volumes/ .

type CloudNodeManager

type CloudNodeManager struct{}

CloudNodeManager holds the QEMU cloud-node-manager configuration.

func (*CloudNodeManager) ExtraArgs

func (c *CloudNodeManager) ExtraArgs() []string

ExtraArgs returns a list of arguments to append to the cloud-node-manager command. Not used on QEMU.

func (*CloudNodeManager) Image

func (c *CloudNodeManager) Image(k8sVersion versions.ValidK8sVersion) (string, error)

Image returns the container image used to provide cloud-node-manager for the cloud-provider. Not used on QEMU.

func (*CloudNodeManager) Path

func (c *CloudNodeManager) Path() string

Path returns the path used by cloud-node-manager executable within the container image. Not used on QEMU.

func (*CloudNodeManager) Supported

func (c *CloudNodeManager) Supported() bool

Supported is used to determine if cloud node manager is implemented for this cloud provider.

type Logger

type Logger struct{}

Logger is a Cloud Logger for QEMU.

func NewLogger

func NewLogger() *Logger

NewLogger creates a new Cloud Logger for QEMU.

func (*Logger) Close

func (l *Logger) Close() error

Close is a no-op.

func (*Logger) Disclose

func (l *Logger) Disclose(msg string)

Disclose writes log information to QEMU's cloud log. This is done by sending a POST request to the QEMU's metadata endpoint.

type Metadata

type Metadata struct{}

Metadata implements core.ProviderMetadata interface for QEMU.

func (Metadata) GetInstance

func (m Metadata) GetInstance(ctx context.Context, providerID string) (metadata.InstanceMetadata, error)

GetInstance retrieves an instance using its providerID.

func (Metadata) GetLoadBalancerEndpoint

func (m Metadata) GetLoadBalancerEndpoint(ctx context.Context) (string, error)

GetLoadBalancerEndpoint returns the endpoint of the load balancer.

func (Metadata) GetSubnetworkCIDR

func (m Metadata) GetSubnetworkCIDR(ctx context.Context) (string, error)

GetSubnetworkCIDR retrieves the subnetwork CIDR from cloud provider metadata.

func (*Metadata) List

List retrieves all instances belonging to the current constellation.

func (*Metadata) Self

Self retrieves the current instance.

func (*Metadata) Supported

func (m *Metadata) Supported() bool

Supported is used to determine if metadata API is implemented for this cloud provider.

func (Metadata) SupportsLoadBalancer

func (m Metadata) SupportsLoadBalancer() bool

SupportsLoadBalancer returns true if the cloud provider supports load balancers.

func (Metadata) UID

func (m Metadata) UID(ctx context.Context) (string, error)

UID returns the UID of the constellation.

Jump to

Keyboard shortcuts

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