kubernetesk8s.io/kubernetes/plugin/pkg/admission/noderestriction Index | Files

package noderestriction

import "k8s.io/kubernetes/plugin/pkg/admission/noderestriction"

Index

Constants

const PluginName = "NodeRestriction"

PluginName is a string with the name of the plugin

Functions

func Register

func Register(plugins *admission.Plugins)

Register registers a plugin

Types

type Plugin

type Plugin struct {
	*admission.Handler
	// contains filtered or unexported fields
}

Plugin holds state for and implements the admission plugin.

func NewPlugin

func NewPlugin(nodeIdentifier nodeidentifier.NodeIdentifier) *Plugin

NewPlugin creates a new NodeRestriction admission plugin. This plugin identifies requests from nodes

func (*Plugin) Admit

Admit checks the admission policy and triggers corresponding actions

func (*Plugin) InspectFeatureGates

func (p *Plugin) InspectFeatureGates(featureGates featuregate.FeatureGate)

InspectFeatureGates allows setting bools without taking a dep on a global variable

func (*Plugin) SetAuthorizer

func (p *Plugin) SetAuthorizer(authz authorizer.Authorizer)

SetAuthorizer sets the authorizer.

func (*Plugin) SetExternalKubeInformerFactory

func (p *Plugin) SetExternalKubeInformerFactory(f informers.SharedInformerFactory)

SetExternalKubeInformerFactory registers an informer factory into Plugin

func (*Plugin) ValidateInitialization

func (p *Plugin) ValidateInitialization() error

ValidateInitialization validates the Plugin was initialized properly

Source Files

admission.go

Version
v1.33.1 (latest)
Published
May 15, 2025
Platform
linux/amd64
Imports
34 packages
Last checked
13 hours ago

Tools for package owners.