Skip to content
This repository was archived by the owner on Jun 23, 2022. It is now read-only.

kube-client-agent: Allow empty --ipaddrs flag. #17

Merged
merged 1 commit into from
Apr 16, 2018

Conversation

yifan-gu
Copy link
Contributor

For peer cert request, we don't need ip address flag since we always
use dns name to contact the peer.

@abhinavdahiya
Copy link
Contributor

--ipaddrs="" caused Error executing kube-client-agent: invalid ipaddress: as splitting empty string still returns an array of length 1 and we would try parsing empty string to ip address.

return fmt.Errorf("invalid ipaddress: %s", addr)
var ips []net.IP

if requestOpts.ipAddresses != "" {
Copy link
Contributor

Choose a reason for hiding this comment

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

Could you add a comment here stating that we allow empty ipAddress flag

For peer cert request, we don't need ip address flag since we always
use dns name to contact the peer.
@yifan-gu yifan-gu force-pushed the allow_empty_ipaddrs branch from 7e94935 to 1a1bdf0 Compare April 16, 2018 21:13
@yifan-gu
Copy link
Contributor Author

@rithujohn191 Addressed the comments.

Copy link
Contributor

@rithujohn191 rithujohn191 left a comment

Choose a reason for hiding this comment

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

lgtm

@yifan-gu yifan-gu merged commit 678cc8e into coreos:master Apr 16, 2018
@yifan-gu yifan-gu deleted the allow_empty_ipaddrs branch April 16, 2018 21:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants