I have created an instance on AWS and installed a LAMP stack on it as per their tutorials and installed an existing magento site on to it.
I pointed my local hosts file at the new server, cleared the var folder (including the cache) and the site loaded. Great!
It has added the path to the root directory after the domain like so:
Causing the 403 forbidden error on every js file. CSS files and images which use the same root URL as per the magento config are loading perfectly.
URL rewrites are working fine, and if I try to access the correct link directly, it loads the file. I've tried messing about with the root urls but found nothing works and the site works on another (cPanel) server.
I'm sure I'm missing a server setting somewhere, but I've been playing around for ages and found nothing.
Thanks in advance for any help :)