CronJob: Use PATCH to adopt Jobs.

This commit is contained in:
Anthony Yeh
2017-04-19 15:30:38 -07:00
parent 33d7788793
commit be1fe95534
5 changed files with 53 additions and 18 deletions

View File

@@ -72,7 +72,7 @@ func init() {
ObjectMeta: metav1.ObjectMeta{Name: saRolePrefix + "cronjob-controller"},
Rules: []rbac.PolicyRule{
rbac.NewRule("get", "list", "watch", "update").Groups(batchGroup).Resources("cronjobs").RuleOrDie(),
rbac.NewRule("get", "list", "watch", "create", "update", "delete").Groups(batchGroup).Resources("jobs").RuleOrDie(),
rbac.NewRule("get", "list", "watch", "create", "update", "delete", "patch").Groups(batchGroup).Resources("jobs").RuleOrDie(),
rbac.NewRule("update").Groups(batchGroup).Resources("cronjobs/status").RuleOrDie(),
rbac.NewRule("list", "delete").Groups(legacyGroup).Resources("pods").RuleOrDie(),
eventsRule(),

View File

@@ -109,6 +109,7 @@ items:
- delete
- get
- list
- patch
- update
- watch
- apiGroups: