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

AWS: kubectl get service should print hostnames for LB services #26749

Merged
merged 1 commit into from
Jun 9, 2016

Conversation

therc
Copy link
Member

@therc therc commented Jun 2, 2016

Fixes #21526

Also test wide outputs. We only guarantee the first IP to be fully printed
if multiple ingresses are present. For AWS, which has no ingress IPs, but
only hostnames, the ELB hostname will be truncated, unless -o=wide is
specified.

@therc
Copy link
Member Author

therc commented Jun 2, 2016

cc @justinsb @thockin

@k8s-github-robot k8s-github-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. release-note-label-needed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Jun 2, 2016
@therc
Copy link
Member Author

therc commented Jun 5, 2016

Rebased and squashed

@k8s-github-robot k8s-github-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 5, 2016
}
}
return strings.Join(result, ",")
r := strings.Join(result, ",")
if !wide && len(r) > 16 {
Copy link
Member

Choose a reason for hiding this comment

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

Nit: Wondering about the "magic constant" here... Is it defined somewhere else? Could we pass it in?

Copy link
Member Author

Choose a reason for hiding this comment

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

It's defined in @thockin's original suggestion. :-) I could pass it in, but then I would have to define a constant somewhere else for the other callers to use and the function would go from one to three arguments.

@justinsb
Copy link
Member

justinsb commented Jun 5, 2016

This LGTM (though with one nit about the magic constant 16). It's annoying that it will never (?) be the full name, but I don't think there's anything we can realistically do about that without making the output super-wide. It does serve as a useful hint to people that there is a dns name, which will really help a lot of new users, as well as for experienced users to have a reminder that there is an ELB on certain services also.

I'm going to put into the 1.3 milestone with a P2; it is an issue that has cropped up a lot so we might consider it a bug fix.

@justinsb justinsb added the priority/backlog Higher priority than priority/awaiting-more-evidence. label Jun 6, 2016
@justinsb justinsb added this to the v1.3 milestone Jun 6, 2016
@therc
Copy link
Member Author

therc commented Jun 6, 2016

I replaced the magic numeric constants with a symbolic one, but I'm not passing it in (yet). We could actually show two extra characters from the original string if we used U+2026 () instead of ..., but I don't know if kubectl is UTF-8 clean.

@deads2k
Copy link
Contributor

deads2k commented Jun 6, 2016

lgtm

@ncdc what are the rules about the milestone?

@ncdc
Copy link
Member

ncdc commented Jun 6, 2016

@smarterclayton @kubernetes/kubectl @kubernetes/rh-ux

@goltermann
Copy link
Contributor

Milestone-wise, this fix looks concise enough to go in 1.3, especially if before we cut Beta on Friday. Who needs to review or apply the LGTM tag?

@therc
Copy link
Member Author

therc commented Jun 7, 2016

I'll take anyone's LGTM. I'm not picky!

@j3ffml j3ffml added lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note-none Denotes a PR that doesn't merit a release note. and removed release-note-label-needed lgtm "Looks good to me", indicates that a PR is ready to be merged. labels Jun 8, 2016
@j3ffml
Copy link
Contributor

j3ffml commented Jun 8, 2016

Please squash, and I'll add label.

…ices

Fixes kubernetes#21526

Also test wide outputs. We only guarantee the first IP to be fully printed
if multiple ingresses are present. For AWS, which has no ingress IPs, but
only hostnames, the ELB hostname will be truncated, unless -o=wide is
specified.
@therc
Copy link
Member Author

therc commented Jun 8, 2016

Squashed. Sorry, I was at an offsite away from civilization the whole day.

@j3ffml j3ffml added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jun 8, 2016
@k8s-bot
Copy link

k8s-bot commented Jun 9, 2016

GCE e2e build/test passed for commit 40f76a9.

@k8s-github-robot
Copy link

@k8s-bot test this [submit-queue is verifying that this PR is safe to merge]

@k8s-bot
Copy link

k8s-bot commented Jun 9, 2016

GCE e2e build/test passed for commit 40f76a9.

@k8s-github-robot
Copy link

Automatic merge from submit-queue

@k8s-github-robot k8s-github-robot merged commit 0b6e0e2 into kubernetes:master Jun 9, 2016
@therc therc deleted the describe-svc branch July 18, 2016 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/backlog Higher priority than priority/awaiting-more-evidence. release-note-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants