1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2025-03-31 03:45:17 +00:00
This commit is contained in:
Shuting Zhao 2020-05-18 20:10:30 -07:00
parent 0e803ae532
commit 74387d2ee4
2 changed files with 2 additions and 1 deletions

View file

@ -62,7 +62,7 @@ func main() {
// Exit for unsupported version of kubernetes cluster // Exit for unsupported version of kubernetes cluster
// https://github.com/nirmata/kyverno/issues/700 // https://github.com/nirmata/kyverno/issues/700
// - supported from v1.12.7+ // - supported from v1.12.7+
if !utils.CompareKubernetesVersion(client, log.Log, 1, 12, 7) { if !utils.HigherThanKubernetesVersion(client, log.Log, 1, 12, 7) {
os.Exit(1) os.Exit(1)
} }

View file

@ -115,6 +115,7 @@ func matchSubjects(ruleSubjects []rbacv1.Subject, userInfo authenticationv1.User
userGroups := append(userInfo.Groups, userInfo.Username) userGroups := append(userInfo.Groups, userInfo.Username)
// TODO: see issue https://github.com/nirmata/kyverno/issues/861
ruleSubjects = append(ruleSubjects, ruleSubjects = append(ruleSubjects,
rbacv1.Subject{Kind: "Group", Name: "system:serviceaccounts:kube-system"}, rbacv1.Subject{Kind: "Group", Name: "system:serviceaccounts:kube-system"},
rbacv1.Subject{Kind: "Group", Name: "system:nodes"}, rbacv1.Subject{Kind: "Group", Name: "system:nodes"},