0

I have a starter (free) tier account with Openshift online. I have an application consisting of two pods, a Node and a Mongo. The pods build and deploy; from the terminal that executes in the web console on the running Node pod I can run curl localhost:8080 and the Node process obligingly spits back my base page.

I have a route that was autogenerated; the web console gives me a link to <myappname>.stuff.starter-east-1.openshiftapps.com and appears to correctly reference the Node service that sits on top of the running Node pod.

However, when I point my browser at that hostname, I get the Openshift error page that tells me that either the route or path was not typed correctly, or the pod isn't running.

I have tried this with my own code and with the example node packages and I see the same thing.

When I use the oc tool to query things about my application, I see that I don't have a router resource - but the route claims to have been exposed on a router. So I think I'm using some kind of default router in the node, and I don't have to launch one in my project, but I'm not sure. Most of the other questions around this topic are for people using the Enterprise product and running on their own hardware, where they have more control at the admin layer over the router package; all the suggestions seem to imply that for the Online product this 'just works'. Any ideas what I am missing?

Update : After some period of time, the example project did work and a browser request was serviced with the basic example page. Looking at the two setups I cannot see any differences, or why my route (in my custome app) never gets activated but the sample project route does.

Mikeb
  • 6,271
  • 3
  • 27
  • 41
  • How long have you been waiting? There are a few bugs open because of routes taking 10+ minutes to actually serve traffic. – Will Gordon Sep 30 '17 at 17:44
  • several hours - is there an oc query to check the status of a route's deployment to the router? Funny story, I went back and checked on my deploy of the test application (which had been exhibiting this behavior too) and suddenly it works. Guess I can try spooling up the "real" application again and waiting – Mikeb Sep 30 '17 at 17:49
  • You said you're on starter-us-east-1? – Will Gordon Sep 30 '17 at 18:27
  • I am. Been waiting on the route for a while now, still getting the 503 page. – Mikeb Sep 30 '17 at 19:03

1 Answers1

0

Turns out the issue was that my application (node) was listening to localhost:8080, when it needs to be listening to 0.0.0.0:8080. I'm not enough of a networking guy to explain why that matters to the router but it does.

Mikeb
  • 6,271
  • 3
  • 27
  • 41
  • 1
    Local host will not accept *any* external traffic, including traffic from the router. The pod must be listening to all connections (0.0.0.0) in order for it to be accessible to the router – Will Gordon Sep 30 '17 at 22:17
  • Ah thanks. If you want to add that as an answer (since it's more clear and I can give you credit then) I will accept it. – Mikeb Oct 01 '17 at 15:16
  • How did you solve this? I am also waiting more then two hours, Still nothing. also on starter-us-east-1 – onderbewustzijn Nov 02 '17 at 00:34
  • I solved it initially by making the above change. However, a week or so ago, a couple of my containers were ... recycled? I don't know - I changed nothing, but OS tried to recreate them, failed, and after a weekend of trying to get it to come back I had what appeared to be living pods and no connection (again). I solved it this time by moving to Google Compute Engine. – Mikeb Nov 06 '17 at 21:00