15

I've set up SSH to my AWS Elastic Beanstalk instance using

eb ssh --setup

and can successfully SSH to my environment. But I can't see my Web application. When I am connected I find myself in an empty directory (ec2-user) and when I

cd /home

I just see

drwx------  3 ec2-user ec2-user 4096 Jan 15 21:37 ec2-user
dr-xr-xr-x 23 root     root     4096 Jan 15 21:03 ..
drwxr-xr-x  3 root     root     4096 Oct 22 23:29 .

Where is my Web application located?

orome
  • 45,163
  • 57
  • 202
  • 418

4 Answers4

33

Do $ sudo find / -name <insert main file name here> to find out.

For example:

$ sudo find / -name \*.php
/var/lib/tomcat8/webapps/ROOT/info.php
/var/lib/tomcat8/webapps/ROOT/index.php
/tmp/deployment/application/ROOT/info.php
/tmp/deployment/application/ROOT/index.php

Or, as you can see, in /var/lib/tomcat8/webapps/ROOT/

You will notice, it depends on the platform. Python for example:

$ sudo find / -name application.py
/opt/python/bundle/2/app/application.py
Nick Humrich
  • 14,905
  • 8
  • 62
  • 85
  • Did I miss this in the docs? Or maybe I'm doing it wrong: how do I execute scripts I've uploaded (e.g. to perform database migration)? – orome Jan 16 '15 at 12:51
  • [Follow up question](http://stackoverflow.com/q/27985153/656912) about how to run once I've found. – orome Jan 16 '15 at 13:36
18

For anyone who doesn't want to wait for find /, I found my rails app at /var/app/ondeck before it successfully deployed and at /var/app/current after it succeeded.

Camden Narzt
  • 2,271
  • 1
  • 23
  • 42
2

When you ssh into your instance, you are in the ~ directory. Type in cd .. to go to the parent directory, which is home. Then cd .. again to get to the root directory. There you can find the var folder, which will contain your files, as the others on here have pointed out.

Joshua Wolff
  • 2,687
  • 1
  • 25
  • 42
0

the content of your WAR is in /var/lib/tomcat8/webapps/ROOT resp. /usr/share/tomcat8/webapps/ROOT

electrobabe
  • 1,549
  • 18
  • 17