Documentation ¶
Index ¶
- Constants
- Variables
- func Mutation(clients *Clients) (http.Handler, []types.Resource, error)
- func NewPCIDeviceClaimValidator(deviceCache v1beta1.PCIDeviceCache, ...) types.Validator
- func NewPCIVMMutator(deviceCache v1beta1.PCIDeviceCache, pciClaimCache v1beta1.PCIDeviceClaimCache, ...) types.Mutator
- func NewPodMutator(deviceCache v1beta1.PCIDeviceCache, ...) types.Mutator
- func NewSriovNetworkDeviceValidator(claimCache v1beta1.PCIDeviceClaimCache) types.Validator
- func RegisterIndexers(clients *Clients)
- func Validation(clients *Clients) (http.Handler, []types.Resource, error)
- type AdmissionWebhookServer
- type Clients
Constants ¶
View Source
const ( VMByName = "harvesterhci.io/vm-by-name" PCIDeviceByResourceName = "harvesterhcio.io/pcidevice-by-resource-name" IommuGroupByNode = "pcidevice.harvesterhci.io/iommu-by-node" VMByPCIDeviceClaim = "harvesterhci.io/vm-by-pcideviceclaim" )
View Source
const (
VMLabel = "harvesterhci.io/vmName"
)
Variables ¶
View Source
var ( MutatorName = "pcidevices-mutator" ValidatorName = "pcidevices-validator" )
Functions ¶
func NewPCIDeviceClaimValidator ¶ added in v0.2.5
func NewPCIDeviceClaimValidator(deviceCache v1beta1.PCIDeviceCache, kubevirtCache kubevirtctl.VirtualMachineCache) types.Validator
func NewPCIVMMutator ¶ added in v0.2.4
func NewPCIVMMutator(deviceCache v1beta1.PCIDeviceCache, pciClaimCache v1beta1.PCIDeviceClaimCache, pciClaimClient v1beta1.PCIDeviceClaimClient) types.Mutator
func NewPodMutator ¶
func NewPodMutator(deviceCache v1beta1.PCIDeviceCache, kubevirtCache kubevirtctl.VirtualMachineCache) types.Mutator
func NewSriovNetworkDeviceValidator ¶ added in v0.2.5
func NewSriovNetworkDeviceValidator(claimCache v1beta1.PCIDeviceClaimCache) types.Validator
func RegisterIndexers ¶
func RegisterIndexers(clients *Clients)
Types ¶
type AdmissionWebhookServer ¶
type AdmissionWebhookServer struct {
// contains filtered or unexported fields
}
AdmissionWebhookServer serves the mutating webhook for pcidevices
func New ¶
func New(ctx context.Context, restConfig *rest.Config) *AdmissionWebhookServer
New helps initialise a new AdmissionWebhookServer
func (*AdmissionWebhookServer) ListenAndServe ¶
func (s *AdmissionWebhookServer) ListenAndServe() error
ListenAndServe starts the http listener and handlers
type Clients ¶
type Clients struct { clients.Clients CoreFactory *ctlcore.Factory HarvesterFactory *ctlharvesterv1.Factory KubevirtFactory *ctlkubevirtv1.Factory PCIFactory *ctlpcidevices.Factory }
Click to show internal directories.
Click to hide internal directories.