-
Notifications
You must be signed in to change notification settings - Fork 822
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
Use k8s.io/component-base/cli to run cmd #2049
Conversation
/assign @RainbowMango |
Nice job, I like this clean up! /lgtm |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wuyingjun-lucky Thanks~
Just a question: is the log format changed before and after the modification?
cmd/agent/main.go
Outdated
@@ -15,25 +15,15 @@ import ( | |||
_ "sigs.k8s.io/controller-runtime/pkg/metrics" | |||
|
|||
apiserver "k8s.io/apiserver/pkg/server" | |||
"k8s.io/component-base/logs" | |||
"k8s.io/component-base/cli" | |||
_ "k8s.io/component-base/logs/json/register" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any comment for this import? Just like:
// for JSON log format registration
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wuyingjun-lucky Thanks~
Just a question: is the log format changed before and after the modification?
It seems no cli.RUN
does not change the format
after:
before:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any comment for this import? Just like:
// for JSON log format registration
DONE
Signed-off-by: wuyingjun <wuyingjun_yewu@cmss.chinamobile.com>
Looks great. Thanks @wuyingjun-lucky /lgtm |
/approve |
[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 |
Signed-off-by: wuyingjun wuyingjun_yewu@cmss.chinamobile.com
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
refer to kubernetes api server
kubernetes replace all commands with k8s.io/component-base/cli to run
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?: