Documentation ¶
Index ¶
- func GetResourceQuotasStatusByNamespace(namespaceStatuses configv1alpha1.AccountQuotasStatusByNamespace, ...) (corev1.ResourceQuotaStatus, bool)
- func InsertResourceQuotasStatus(namespaceStatuses *configv1alpha1.AccountQuotasStatusByNamespace, ...)
- func NewAccountResourceQuota(ctrlCtx *controllers.Context) admission.ValidationInterface
- func NewQuotaConfiguration(f quota.ListerForResourceFunc) quota.Configuration
- func RecommendedDefaultResourceQuotaControllerConfiguration(obj *kubectrlmgrconfigv1alpha1.ResourceQuotaControllerConfiguration)
- func Register(ctrlCtx *controllers.Context) error
- func RemoveResourceQuotasStatusByNamespace(namespaceStatuses *configv1alpha1.AccountQuotasStatusByNamespace, ...)
- type ByName
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetResourceQuotasStatusByNamespace ¶
func GetResourceQuotasStatusByNamespace(namespaceStatuses configv1alpha1.AccountQuotasStatusByNamespace, namespace string) (corev1.ResourceQuotaStatus, bool)
func InsertResourceQuotasStatus ¶
func InsertResourceQuotasStatus(namespaceStatuses *configv1alpha1.AccountQuotasStatusByNamespace, newStatus configv1alpha1.AccountQuotaStatusByNamespace)
func NewAccountResourceQuota ¶
func NewAccountResourceQuota(ctrlCtx *controllers.Context) admission.ValidationInterface
NewAccountResourceQuota configures an admission controller that can enforce accountQuota constraints using the provided registry. The registry must have the capability to handle group/kinds that are persisted by the server this admission controller is intercepting
func NewQuotaConfiguration ¶
func NewQuotaConfiguration(f quota.ListerForResourceFunc) quota.Configuration
NewQuotaConfiguration creates a new quota configuration that can be used to create quota registry
func RecommendedDefaultResourceQuotaControllerConfiguration ¶
func RecommendedDefaultResourceQuotaControllerConfiguration(obj *kubectrlmgrconfigv1alpha1.ResourceQuotaControllerConfiguration)
RecommendedDefaultResourceQuotaControllerConfiguration defaults a pointer to a ResourceQuotaControllerConfiguration struct. This will set the recommended default values, but they may be subject to change between API versions. This function is intentionally not registered in the scheme as a "normal" `SetDefaults_Foo` function to allow consumers of this type to set whatever defaults for their embedded configs. Forcing consumers to use these defaults would be problematic as defaulting in the scheme is done as part of the conversion, and there would be no easy way to opt-out. Instead, if you want to use this defaulting method run it in your wrapper struct of this type in its `SetDefaults_` method.
func Register ¶
func Register(ctrlCtx *controllers.Context) error
Register registers the quota controller
func RemoveResourceQuotasStatusByNamespace ¶
func RemoveResourceQuotasStatusByNamespace(namespaceStatuses *configv1alpha1.AccountQuotasStatusByNamespace, namespace string)