Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grant karmada-agent permission to access resourceinterpretercustomizations #2984

Merged
merged 1 commit into from
Dec 22, 2022

Conversation

jwcesign
Copy link
Member

@jwcesign jwcesign commented Dec 21, 2022

Signed-off-by: jwcesign jiangwei115@huawei.com

What type of PR is this?
/kind bug

What this PR does / why we need it:

  • Grant karmada-agent permission to acccess resourceinterpretercustomizations

Which issue(s) this PR fixes:
Fixes #2982

Special notes for your reviewer:
none

Does this PR introduce a user-facing change?:

`karmadactl init`: Grant karmada-agent permission to access resourceinterpretercustomizations.

@karmada-bot karmada-bot added the kind/bug Categorizes issue or PR as related to a bug. label Dec 21, 2022
…tions

Signed-off-by: jwcesign <jiangwei115@huawei.com>
@karmada-bot karmada-bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Dec 21, 2022
@jwcesign
Copy link
Member Author

cc @XiShanYongYe-Chang @lonelyCZ

@codecov-commenter
Copy link

codecov-commenter commented Dec 21, 2022

Codecov Report

Merging #2984 (c174728) into master (9068240) will not change coverage.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #2984   +/-   ##
=======================================
  Coverage   38.58%   38.58%           
=======================================
  Files         206      206           
  Lines       18820    18820           
=======================================
  Hits         7261     7261           
  Misses      11129    11129           
  Partials      430      430           
Flag Coverage Δ
unittests 38.58% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
pkg/karmadactl/cmdinit/karmada/rbac.go 88.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Member

@XiShanYongYe-Chang XiShanYongYe-Chang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lonelyCZ
Copy link
Member

Thanks @jwcesign , have you tested it in your env?

And please update the release-note to

`karmadactl init`: Grant karmada-agent permission to access resourceinterpretercustomizations.

and it could be cherry-picked to release-1.4 after merged.

@jwcesign
Copy link
Member Author

jwcesign commented Dec 21, 2022

Thanks @jwcesign , have you tested it in your env?

And please update the release-note to

`karmadactl init`: Grant karmada-agent permission to access resourceinterpretercustomizations.

and it could be cherry-picked to release-1.4 after merged.

Updated.
Yeah, I tested it, and it works fine and the error has gone. The log now looks like:

I1221 07:04:38.167481       1 reflector.go:559] k8s.io/client-go/informers/factory.go:134: Watch close - *v1.Pod total 7 items received
I1221 07:04:38.232763       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:04:48.242501       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:04:58.253555       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:05:08.264764       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:05:18.273936       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:05:28.283229       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:05:38.051841       1 reflector.go:559] k8s.io/client-go/dynamic/dynamicinformer/informer.go:91: Watch close - *unstructured.Unstructured total 0 items received
I1221 07:05:38.292174       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:05:48.301247       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:05:58.311827       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:06:08.325698       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:06:18.335299       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:06:28.345986       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:06:38.360336       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:06:48.370071       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:06:58.381978       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:07:01.166452       1 reflector.go:559] k8s.io/client-go/informers/factory.go:134: Watch close - *v1.Node total 13 items received
I1221 07:07:06.431935       1 reflector.go:559] k8s.io/client-go/dynamic/dynamicinformer/informer.go:91: Watch close - *unstructured.Unstructured total 9 items received
I1221 07:07:08.394397       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:07:18.407074       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member
I1221 07:07:28.422169       1 cluster_status_controller.go:109] Syncing cluster status: kind-karmada-member

@RainbowMango
Copy link
Member

Have we granted permission to karmada-controller-manager as well?

@lonelyCZ
Copy link
Member

Have we granted permission to karmada-controller-manager as well?

karmada-controller-manager seemingly have all permissions.

@lonelyCZ
Copy link
Member

/lgtm

@karmada-bot karmada-bot added the lgtm Indicates that a PR is ready to be merged. label Dec 21, 2022
Copy link
Member

@RainbowMango RainbowMango left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/approve

@karmada-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: RainbowMango

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@karmada-bot karmada-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 22, 2022
@karmada-bot karmada-bot merged commit 0ef9509 into karmada-io:master Dec 22, 2022
karmada-bot added a commit that referenced this pull request Dec 22, 2022
…-upstream-release-1.4

Automated cherry pick of #2984: Grant karmada-agent permission to access resourceinterpretercustomizations
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/bug Categorizes issue or PR as related to a bug. lgtm Indicates that a PR is ready to be merged. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

karmada-agent keep logging error about resourceinterpretercustomizations resource
6 participants