review: several fixes and addressing comments
Kubernetes-commit: 70dea6e4a8495ff028ccc8dc8e8aec04b93287c3
This commit is contained in:
parent
54dfffd2ea
commit
07fdbc261e
|
|
@ -63,6 +63,7 @@ var (
|
||||||
SuggestedFlowSchemaKubeControllerManager, // references "workload-high" priority-level
|
SuggestedFlowSchemaKubeControllerManager, // references "workload-high" priority-level
|
||||||
SuggestedFlowSchemaKubeScheduler, // references "workload-high" priority-level
|
SuggestedFlowSchemaKubeScheduler, // references "workload-high" priority-level
|
||||||
SuggestedFlowSchemaKubeSystemServiceAccounts, // references "workload-high" priority-level
|
SuggestedFlowSchemaKubeSystemServiceAccounts, // references "workload-high" priority-level
|
||||||
|
SuggestedFlowSchemaServiceAccounts, // references "workload-low" priority-level
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -98,7 +99,7 @@ var (
|
||||||
MandatoryFlowSchemaExempt = newFlowSchema(
|
MandatoryFlowSchemaExempt = newFlowSchema(
|
||||||
"exempt",
|
"exempt",
|
||||||
flowcontrol.PriorityLevelConfigurationNameExempt,
|
flowcontrol.PriorityLevelConfigurationNameExempt,
|
||||||
0, // matchingPrecedence
|
1, // matchingPrecedence
|
||||||
"", // distinguisherMethodType
|
"", // distinguisherMethodType
|
||||||
flowcontrol.PolicyRulesWithSubjects{
|
flowcontrol.PolicyRulesWithSubjects{
|
||||||
Subjects: groups(user.SystemPrivilegedGroup),
|
Subjects: groups(user.SystemPrivilegedGroup),
|
||||||
|
|
@ -221,7 +222,7 @@ var (
|
||||||
// Suggested FlowSchema objects
|
// Suggested FlowSchema objects
|
||||||
var (
|
var (
|
||||||
SuggestedFlowSchemaSystemNodes = newFlowSchema(
|
SuggestedFlowSchemaSystemNodes = newFlowSchema(
|
||||||
"system-nodes", "system", 1500,
|
"system-nodes", "system", 500,
|
||||||
flowcontrol.FlowDistinguisherMethodByUserType,
|
flowcontrol.FlowDistinguisherMethodByUserType,
|
||||||
flowcontrol.PolicyRulesWithSubjects{
|
flowcontrol.PolicyRulesWithSubjects{
|
||||||
Subjects: groups(user.NodesGroup), // the nodes group
|
Subjects: groups(user.NodesGroup), // the nodes group
|
||||||
|
|
@ -239,7 +240,7 @@ var (
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
SuggestedFlowSchemaSystemLeaderElection = newFlowSchema(
|
SuggestedFlowSchemaSystemLeaderElection = newFlowSchema(
|
||||||
"system-leader-election", "leader-election", 2500,
|
"system-leader-election", "leader-election", 100,
|
||||||
flowcontrol.FlowDistinguisherMethodByUserType,
|
flowcontrol.FlowDistinguisherMethodByUserType,
|
||||||
flowcontrol.PolicyRulesWithSubjects{
|
flowcontrol.PolicyRulesWithSubjects{
|
||||||
Subjects: append(
|
Subjects: append(
|
||||||
|
|
@ -262,19 +263,19 @@ var (
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
SuggestedFlowSchemaWorkloadLeaderElection = newFlowSchema(
|
SuggestedFlowSchemaWorkloadLeaderElection = newFlowSchema(
|
||||||
"workload-leader-election", "leader-election", 2500,
|
"workload-leader-election", "leader-election", 200,
|
||||||
flowcontrol.FlowDistinguisherMethodByUserType,
|
flowcontrol.FlowDistinguisherMethodByUserType,
|
||||||
flowcontrol.PolicyRulesWithSubjects{
|
flowcontrol.PolicyRulesWithSubjects{
|
||||||
Subjects: kubeSystemServiceAccount(flowcontrol.NameAll),
|
Subjects: kubeSystemServiceAccount(flowcontrol.NameAll),
|
||||||
ResourceRules: []flowcontrol.ResourcePolicyRule{
|
ResourceRules: []flowcontrol.ResourcePolicyRule{
|
||||||
resourceRule(
|
resourceRule(
|
||||||
[]string{flowcontrol.VerbAll},
|
[]string{"get", "create", "update"},
|
||||||
[]string{corev1.GroupName},
|
[]string{corev1.GroupName},
|
||||||
[]string{"endpoints", "configmaps"},
|
[]string{"endpoints", "configmaps"},
|
||||||
[]string{flowcontrol.NamespaceEvery},
|
[]string{flowcontrol.NamespaceEvery},
|
||||||
false),
|
false),
|
||||||
resourceRule(
|
resourceRule(
|
||||||
[]string{flowcontrol.VerbAll},
|
[]string{"get", "create", "update"},
|
||||||
[]string{coordinationv1.GroupName},
|
[]string{coordinationv1.GroupName},
|
||||||
[]string{"leases"},
|
[]string{"leases"},
|
||||||
[]string{flowcontrol.NamespaceEvery},
|
[]string{flowcontrol.NamespaceEvery},
|
||||||
|
|
@ -283,7 +284,7 @@ var (
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
SuggestedFlowSchemaKubeControllerManager = newFlowSchema(
|
SuggestedFlowSchemaKubeControllerManager = newFlowSchema(
|
||||||
"kube-controller-manager", "workload-high", 3500,
|
"kube-controller-manager", "workload-high", 800,
|
||||||
flowcontrol.FlowDistinguisherMethodByNamespaceType,
|
flowcontrol.FlowDistinguisherMethodByNamespaceType,
|
||||||
flowcontrol.PolicyRulesWithSubjects{
|
flowcontrol.PolicyRulesWithSubjects{
|
||||||
Subjects: users(user.KubeControllerManager),
|
Subjects: users(user.KubeControllerManager),
|
||||||
|
|
@ -301,7 +302,7 @@ var (
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
SuggestedFlowSchemaKubeScheduler = newFlowSchema(
|
SuggestedFlowSchemaKubeScheduler = newFlowSchema(
|
||||||
"kube-scheduler", "workload-high", 3500,
|
"kube-scheduler", "workload-high", 800,
|
||||||
flowcontrol.FlowDistinguisherMethodByNamespaceType,
|
flowcontrol.FlowDistinguisherMethodByNamespaceType,
|
||||||
flowcontrol.PolicyRulesWithSubjects{
|
flowcontrol.PolicyRulesWithSubjects{
|
||||||
Subjects: users(user.KubeScheduler),
|
Subjects: users(user.KubeScheduler),
|
||||||
|
|
@ -319,7 +320,7 @@ var (
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
SuggestedFlowSchemaKubeSystemServiceAccounts = newFlowSchema(
|
SuggestedFlowSchemaKubeSystemServiceAccounts = newFlowSchema(
|
||||||
"kube-system-service-accounts", "workload-high", 3500,
|
"kube-system-service-accounts", "workload-high", 900,
|
||||||
flowcontrol.FlowDistinguisherMethodByNamespaceType,
|
flowcontrol.FlowDistinguisherMethodByNamespaceType,
|
||||||
flowcontrol.PolicyRulesWithSubjects{
|
flowcontrol.PolicyRulesWithSubjects{
|
||||||
Subjects: kubeSystemServiceAccount(flowcontrol.NameAll),
|
Subjects: kubeSystemServiceAccount(flowcontrol.NameAll),
|
||||||
|
|
@ -337,7 +338,7 @@ var (
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
SuggestedFlowSchemaServiceAccounts = newFlowSchema(
|
SuggestedFlowSchemaServiceAccounts = newFlowSchema(
|
||||||
"service-accounts", "workload-low", 7500,
|
"service-accounts", "workload-low", 9000,
|
||||||
flowcontrol.FlowDistinguisherMethodByUserType,
|
flowcontrol.FlowDistinguisherMethodByUserType,
|
||||||
flowcontrol.PolicyRulesWithSubjects{
|
flowcontrol.PolicyRulesWithSubjects{
|
||||||
Subjects: groups(serviceaccount.AllServiceAccountsGroup),
|
Subjects: groups(serviceaccount.AllServiceAccountsGroup),
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue