Closed Like0x closed 1 year ago
I am thinking maybe moving it to the InitHttpClient
, because there are already similar check
https://github.com/cyberark/kubeletctl/blob/4b4b989e59ea6b0a9e64c87cabf407a45c39b137/pkg/api/requests.go#L53-L55
Thank you for your contribution :)
I am thinking maybe moving it to the
InitHttpClient
, because there are already similar check
I found that --token-file
parameter did not work properly on the authenticated 10250 port. So I observed the code and found that the config variable was re-assigned in exec.go. It did not inherit the previous configuration. So it did not carry the token. Since I am not very familiar with the project, I found that GlobalBearerToken
can be used as a temporary judgment basis. If there is a better way, you can make modifications.
Thank you for your clarification. For now, I merged your solution, and it looks good. But maybe in the future, we will need to do some modifications so it will be before the function.
Thanks again, I appreciate your contribution
Desired Outcome
Update exec.go if needs a token
Implemented Changes
This is configured using the
GlobalBearerToken
global variableConnected Issue/Story
null
Definition of Done
At least 1 todo must be completed in the sections below for the PR to be merged.
Changelog
Test coverage
Documentation
README
s) were updated in this PRBehavior
Security