Documentation ¶
Overview ¶
Package kvmdevice implements a Kubernetes device plugin for the virtual KVM device. Using the device plugin API allows us to take advantage of the scheduler to locate pods on machines eligible for KVM and also allows granular access control to KVM using quotas instead of needing privileged access. Since KVM devices are virtual, this plugin emulates a huge number of them so that we never run out.
Index ¶
- Variables
- type Plugin
- func (k *Plugin) Allocate(ctx context.Context, req *deviceplugin.AllocateRequest) (*deviceplugin.AllocateResponse, error)
- func (k *Plugin) GetDevicePluginOptions(context.Context, *deviceplugin.Empty) (*deviceplugin.DevicePluginOptions, error)
- func (k *Plugin) GetInfo(context.Context, *pluginregistration.InfoRequest) (*pluginregistration.PluginInfo, error)
- func (k *Plugin) ListAndWatch(req *deviceplugin.Empty, s deviceplugin.DevicePlugin_ListAndWatchServer) error
- func (k *Plugin) NotifyRegistrationStatus(ctx context.Context, req *pluginregistration.RegistrationStatus) (*pluginregistration.RegistrationStatusResponse, error)
- func (k *Plugin) Run(ctx context.Context) error
Constants ¶
This section is empty.
Variables ¶
View Source
var Name corev1.ResourceName = "devices.monogon.dev/kvm"
Name is the name of the KVM devices this plugin exposes
Functions ¶
This section is empty.
Types ¶
type Plugin ¶
type Plugin struct { *deviceplugin.UnimplementedDevicePluginServer KubeletDirectory *localstorage.DataKubernetesKubeletDirectory // contains filtered or unexported fields }
func (*Plugin) Allocate ¶
func (k *Plugin) Allocate(ctx context.Context, req *deviceplugin.AllocateRequest) (*deviceplugin.AllocateResponse, error)
func (*Plugin) GetDevicePluginOptions ¶
func (k *Plugin) GetDevicePluginOptions(context.Context, *deviceplugin.Empty) (*deviceplugin.DevicePluginOptions, error)
func (*Plugin) GetInfo ¶
func (k *Plugin) GetInfo(context.Context, *pluginregistration.InfoRequest) (*pluginregistration.PluginInfo, error)
func (*Plugin) ListAndWatch ¶
func (k *Plugin) ListAndWatch(req *deviceplugin.Empty, s deviceplugin.DevicePlugin_ListAndWatchServer) error
func (*Plugin) NotifyRegistrationStatus ¶
func (k *Plugin) NotifyRegistrationStatus(ctx context.Context, req *pluginregistration.RegistrationStatus) (*pluginregistration.RegistrationStatusResponse, error)
Click to show internal directories.
Click to hide internal directories.