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

why "kubectl port-forward" just binds the 127.0.0.1 but not 0.0.0.0? #40053

Closed
tianshapjq opened this issue Jan 18, 2017 · 4 comments
Closed

Comments

@tianshapjq
Copy link
Contributor

What keywords did you search in Kubernetes issues before filing this one? (If you have found any duplicates, you should instead reply there.):
port-forward

Kubernetes version (use kubectl version):
Client Version: version.Info{Major:"1", Minor:"5", GitVersion:"v1.5.1+82450d0", GitCommit:"79113147d3cacf4a3c07d13bddff5aa7c0f3fe98", GitTreeState:"dirty", BuildDate:"2017-01-16T03:40:49Z", GoVersion:"go1.7.4", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"5", GitVersion:"v1.5.1+82450d0", GitCommit:"79113147d3cacf4a3c07d13bddff5aa7c0f3fe98", GitTreeState:"dirty", BuildDate:"2017-01-16T03:36:00Z", GoVersion:"go1.7.4", Compiler:"gc", Platform:"linux/amd64"}

What happened:
the "kubectl port-forward" command binds the address 127.0.0.1 which means we can't visit the forward port from outside the server. Why don't we bind the address 0.0.0.0 which can make the forward be visited outside the server?

What you expected to happen:
change the binding address to 0.0.0.0

@colemickens
Copy link
Contributor

colemickens commented Jan 18, 2017

dupe of: #36152, #29678

@tianshapjq
Copy link
Contributor Author

thanks~ @colemickens

@satya541
Copy link

kubectl port-forward --address 0.0.0.0

@simonfontana
Copy link

@satya541 is correct but you need > v1.13.0. See #46517.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants