Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
bda95a59
Unverified
Commit
bda95a59
authored
Jan 09, 2017
by
Jordan Liggitt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow node-controller to update node status
parent
e827393f
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
1 deletion
+28
-1
controller_policy.go
...auth/authorizer/rbac/bootstrappolicy/controller_policy.go
+5
-1
controller-roles.yaml
...rizer/rbac/bootstrappolicy/testdata/controller-roles.yaml
+23
-0
No files found.
plugin/pkg/auth/authorizer/rbac/bootstrappolicy/controller_policy.go
View file @
bda95a59
...
@@ -166,7 +166,11 @@ func init() {
...
@@ -166,7 +166,11 @@ func init() {
addControllerRole
(
rbac
.
ClusterRole
{
addControllerRole
(
rbac
.
ClusterRole
{
ObjectMeta
:
api
.
ObjectMeta
{
Name
:
saRolePrefix
+
"node-controller"
},
ObjectMeta
:
api
.
ObjectMeta
{
Name
:
saRolePrefix
+
"node-controller"
},
Rules
:
[]
rbac
.
PolicyRule
{
Rules
:
[]
rbac
.
PolicyRule
{
rbac
.
NewRule
(
"get"
,
"list"
,
"update"
)
.
Groups
(
legacyGroup
)
.
Resources
(
"nodes"
)
.
RuleOrDie
(),
rbac
.
NewRule
(
"get"
,
"list"
,
"update"
,
"delete"
)
.
Groups
(
legacyGroup
)
.
Resources
(
"nodes"
)
.
RuleOrDie
(),
rbac
.
NewRule
(
"update"
)
.
Groups
(
legacyGroup
)
.
Resources
(
"nodes/status"
)
.
RuleOrDie
(),
// used for pod eviction
rbac
.
NewRule
(
"update"
)
.
Groups
(
legacyGroup
)
.
Resources
(
"pods/status"
)
.
RuleOrDie
(),
rbac
.
NewRule
(
"list"
,
"delete"
)
.
Groups
(
legacyGroup
)
.
Resources
(
"pods"
)
.
RuleOrDie
(),
eventsRule
(),
eventsRule
(),
},
},
})
})
...
...
plugin/pkg/auth/authorizer/rbac/bootstrappolicy/testdata/controller-roles.yaml
View file @
bda95a59
...
@@ -533,6 +533,7 @@ items:
...
@@ -533,6 +533,7 @@ items:
resources
:
resources
:
-
nodes
-
nodes
verbs
:
verbs
:
-
delete
-
get
-
get
-
list
-
list
-
update
-
update
...
@@ -540,6 +541,28 @@ items:
...
@@ -540,6 +541,28 @@ items:
-
"
"
-
"
"
attributeRestrictions
:
null
attributeRestrictions
:
null
resources
:
resources
:
-
nodes/status
verbs
:
-
update
-
apiGroups
:
-
"
"
attributeRestrictions
:
null
resources
:
-
pods/status
verbs
:
-
update
-
apiGroups
:
-
"
"
attributeRestrictions
:
null
resources
:
-
pods
verbs
:
-
delete
-
list
-
apiGroups
:
-
"
"
attributeRestrictions
:
null
resources
:
-
events
-
events
verbs
:
verbs
:
-
create
-
create
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment