mirror of
https://github.com/rancher/k3k.git
synced 2026-08-18 03:46:31 +00:00
Show correct allocatable resources when a Policy is applied (#638)
* wip * wip * wip * fix lint and tests * fixed bugs for missing resources * cleanup and refactor * removed coreClient from configureNode * added comments to distribute algorithm
This commit is contained in:
@@ -386,6 +386,11 @@ func (s *SharedAgent) role(ctx context.Context) error {
|
||||
Resources: []string{"events"},
|
||||
Verbs: []string{"create"},
|
||||
},
|
||||
{
|
||||
APIGroups: []string{""},
|
||||
Resources: []string{"resourcequotas"},
|
||||
Verbs: []string{"get", "watch", "list"},
|
||||
},
|
||||
{
|
||||
APIGroups: []string{"networking.k8s.io"},
|
||||
Resources: []string{"ingresses"},
|
||||
|
||||
@@ -165,6 +165,7 @@ func nodeEventHandler(r *VirtualClusterPolicyReconciler) handler.Funcs {
|
||||
if oldNode.Spec.PodCIDR != newNode.Spec.PodCIDR {
|
||||
podCIDRChanged = true
|
||||
}
|
||||
|
||||
if !reflect.DeepEqual(oldNode.Spec.PodCIDRs, newNode.Spec.PodCIDRs) {
|
||||
podCIDRChanged = true
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user