简体   繁体   中英

Deploying Rails App to AWS Elastic Beanstalk, time out

I have an existing app that runs fine on localhost. I tried to deploy it to AWS Elastic Beanstalk today via the step-by-step instructions on this page

After using git aws.push to deploy it onto AWS, I wait for the status of the environment to go to green, and try to access the url it gives me. I get a timeout error after a long while of waiting.

I know this is really not much to go off of, but I'm equally stumped. Is there some kind of server side error log or console log (similar to what I see when I 'rails s' on my computer) so I can see what the AWS environment is writing out? I'm not even sure where to start debugging here.

Your first step is to snapshot your logs from the logs tab of your elastic beanstalk's environment you deployed to. This will give you a snapshot of the recent log activity. If you do need to ssh into the EC2 instance that backs your Elastic Beanstalk instance, it's not immediately evident how to do that. You first need to generate a key pair and download it something like my-key.pem. Then associate that key with the Elastic beanstalk application by editing the configuration and on the first tab, add my-key (note it's just the name, not the actual key). To ssh into your EC2 instance you use ssh -i /path/to/my-key.pem ec2-user@

You get the ec2 public url from the ec2 console. Hope all this helps.

First you'll need to ssh into your server

https://stackoverflow.com/a/4921866/274695

Then, you can look your application logs (passenger.log, production.log) at /var/app/support/logs/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM