0

I registered a virtual domain with namecheap and set up an Amazon EC2 instance (I also set up an elastic IP, it looks like I did this correctly).

I was able to have the EC2 instance successfully point to my virtual domain. I used Apache/2.4.29 (Ubuntu) Server for this.

I am using Filezilla to transfer via SFTP, I can successfully SSH into filezilla and upload files to the server successfully as well. However, the files don't render on the actual website when I visit the URL.

I checked out some tutorials and think I set up my security groups correctly. I don't see a public_html folder to upload files though, and this seems pretty ubiquitous as a standard directory. When I visit my domain I just see the default apache index.html file.

Any ideas would be appreciated, I leaned a lot on this tutorial when setting things up: https://www.youtube.com/watch?v=Qxs7CYguo70

2 Answers 2

0

Are you uploading your files into the correct folder?

I upload my files to /var/www/html using filezilla and that works

0

I am using Filezilla to transfer via SFTP, I can successfully SSH into filezilla and upload files to the server successfully as well. However, the files don't render on the actual website when I visit the URL.

It's not enough to just dump files anywhere on the server. The location where you need to upload the files is the location that you configured in Apache – that's the DocumentRoot option inside whatever <VirtualHost> you added. A fresh Apache installation will have one "default" vhost that's configured to use either /srv/http or /var/www(/html), usually.


I don't see a public_html folder to upload files though, and this seems pretty ubiquitous as a standard directory.

No – although usage of public_html for each domain's files is pretty common on shared hosting systems, which have been pre-configured in a certain way by the server admins, but it is not actually the default configuration on "fresh" Apache web servers.

(The original purpose of public_html is actually for "tilde" user directories, where each user could get their own "~subdirectory" under the system's main domain. The shared hosting systems obviously drew inspiration from that, adapted for the "personal domain" model.)

You must log in to answer this question.

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