Common causes of "No application seems to be running here!"

preview

#1

If your application preview is timing out, giving errors, or just not loading please try the following to diagnose the cause:

Check your application is running

If you run sudo ps aux in a terminal you’ll see all the applications running in your workspace. Make sure you can see your application in the list. When workspaces come out of hibernation all processes are stopped and are not started automatically so you may need to manually start your application.

Also please ensure any relevant databases are also running, as they also do not start automatically when coming out of hibernation. If you’re using mysql you should see mysql in this list and can use mysql-ctl start to restart it.

Check your application is running on port 8080

If you run the command sudo netstat -tulpn in a terminal you’ll see all the applications that are running in your workspace. You should see your application in this list and in the 4th column (titled Local Address) you should see the address 0.0.0.0:8080.

If you see the address 127.0.0.1 or another number after the colon your application is configured incorrectly. Your application must be running using the hostname / ip of 0.0.0.0 and port 8080 to work with application preview. Please refer to our Run an application documentation page to fix this.

Check you can use curl to access your application

Try running curl -v 0.0.0.0:8080 in a terminal and note the response code and information. You should get the response code 200 or 204 back from your application. If you get a response code of 4XX or 5XX there is something wrong with your application code and you’ll need to fix that.

If your app is private, make sure you’re sending authentication headers

If you’re trying to curl to your application from an external machine, or connect to it from a 3rd party service (such as an OAuth provider) this will not work when your application is private.

You can fix this by making your application preview public via the share menu in the top right. Or you can pass your cloud9 username and password as the HTTP Authorization header when sending the request.


Application previews are not working right now
C9 Application is not working
#2

So what does it mean if “curl” says that your application is running, but going to the web page produces “No application seems to be running here”?


#3

Usually this means that you are running on a port that is not accessible from the internet. Please make sure you are listening on $IP (0.0.0.0) and $PORT (8080), and try again.


#4

That’s what I used:curl -v “0.0.0.0:8080” works, but my web page gives “No application seems to be running”


#5

Here’s the curl response:

$ curl -v "http://0.0.0.0:8080"
* Rebuilt URL to: http://0.0.0.0:8080/
* Hostname was NOT found in DNS cache
*   Trying 0.0.0.0...
* Connected to 0.0.0.0 (127.0.0.1) port 8080 (#0)
> GET / HTTP/1.1
> User-Agent: curl/7.35.0
> Host: 0.0.0.0:8080
> Accept: */*
> 
< HTTP/1.1 200 OK 
* Server WEBrick/1.3.1 (Ruby/2.3.0/2015-12-25) is not blacklisted
< Server: WEBrick/1.3.1 (Ruby/2.3.0/2015-12-25)
< Date: Tue, 01 Aug 2017 00:49:43 GMT
< Content-Length: 30
< Connection: Keep-Alive
< 
yabbadabbado! got GET request
* Connection #0 to host 0.0.0.0 left intact

But when I go to my web page, I get “No application …”


#6

Your server must listen on host 0.0.0.0, instead of 127.0.0.1.
run netstat -tulpn to see on which host it is listening.


#7

So this is great, but what do you do when none of these return the expected information. Telling what to check without telling how to fix it isn’t overly helpful.

When I run the first one, what should I expect to see? And if it’s not there, how to I fix it?

When I run the second one and it’s not there, how do I fix it?

When I run the third one and it gets a error, how do I fix it?

Saying “there’s a problem and you need to fix it” doesn’t really help with actually fixing it.