0

Let's say I've logged into an image that was spun up by an automated process and it's serving up a website (in my case it's a Rails site). I'm rooted, but don't know where to find the source code. Given that there are processes running that are serving the code, or at least a compiled version of it, is there a reliable way to figure out where on the instance the source code lives?

2 Answers 2

0

Note a file the web server use and find it.

In exemple;

find / -name "index.html"

It happened to me in the past as I'am more windows than linux. (I created a cloud linux VM to make a webserver to learn and I didnt knew where the home folder was to the webserver service)

0

You can use ss -tp to list all open ports with their process ids. Use ps aux | grep PID to display the command executed.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .