1

In version 4.0.2 of Google Container Engine I am able to create a service on high ports 8080, 9000, etc but when I try lower ports 80, 81, etc, the service does not work. I have checked the firewall rules and tried with a brand new project without success. I have checked the release notes and there is a bug that prevents two services to reference the same port, but, that's not the case. Any hints of what might happen?

  • Port 80 is considered reserved for an HTTP server. Do you have one running on your system? Also, [this post](http://stackoverflow.com/questions/1694144/can-two-applications-listen-to-the-same-port) may answer your questions about services sharing a port. – Bob Kaufman Nov 14 '14 at 21:31
  • The question is about Google kubernetes Container Engine, not about standard tcp/ip networking. I was refering to a kubernetes service not a standard service running in a single node (ex. Linux machine) – Joan Marc Carbo Arnau Nov 14 '14 at 21:48

1 Answers1

2

You currently cannot bind to a low port (1-1024) because the tcp proxying service runs as an unprivileged user. If you look in your logs you should see an error similar to:

E1030 07:10:54.345547 05091 proxier.go:411] Failed to get a socket for playground: listen tcp 0.0.0.0:80: bind: permission denied

This is why the examples all use high number ports.

You can try port 8080 or 8443 for standard unprivileged http/s ports until GKE supports binding to low numbered ports.

Robert Bailey
  • 17,866
  • 3
  • 50
  • 58