-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
Validations #432
Validations #432
Conversation
gianrubio
commented
Mar 13, 2017
•
edited
Loading
edited
- Validate if configmap exist and is in the namespace/name format
- Verifiy if watch-namespace option exist
@@ -234,6 +244,13 @@ func createApiserverClient(apiserverHost string, kubeConfig string) (*client.Cli | |||
if err != nil { | |||
return nil, err | |||
} | |||
|
|||
// test connection | |||
_, err = client.ServerVersion() |
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.
Why are you doing this?
If is not possible to reach the api server this error is returned.
In any other case the client will retry the connection.
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.
I didn't realise this, rolled back.
Verifiy if watch-namespace option exist
3524361
to
c6195c4
Compare
/lgtm |
@gianrubio thanks! |