Cannot run Vaadin app on AWS Elastic Beanstalk

Hi, I’m trying to run my app on Elastic Beanstalk. I created a War file and uploaed it to AWS as described here:

https://vaadin.com/wiki/-/wiki/Main/Amazon+Elastic+Beanstalk+HOWTO

These instructions are helpful but somewhat out of date.

When the code is deployed, the state switches to “DEGRADED” with the severity of “SEVERE”. When i pulled the logs I saw:

------------------------------------- /var/log/nginx/error.log -------------------------------------
2017/04/03 21:17:32 [error]
29340#0: *1 connect() failed (111: Connection refused) while connecting to upstream, client: 50.252.224.113, server: , request: “GET / HTTP/1.1”, upstream: “http://127.0.0.1:5000/”,
host: “lowcost-env.minuvpn9c8.us-east-1.elasticbeanstalk.com

which I think means there’s an nginx proxy server that wants my app to be serving on port 5000, which it isn’t.
I don’t know whether that’s because it’s not serving at all, or because it’s misconfigured for beanstalk.

Help would be hugely appreciated.

thanks.