I'm very new to AWS and Nginx.
When I get an access to my elastic ip address for web server EC2 instance, I get a 404 not found error.
How come it shows 404 not found error although I have uploaded files to the directory I set as root directory in nginx.conf file?
After I edited the nginx.conf file, I did reload nginx as well.
On EC2
$ ls sites/
LICENSE README.md css fonts index.html js
nginx.conf
events {}
http {
server {
listen 80;
server_name MY_IP_ADDRESS_HERE;
root /sites/;
}
}
Additional Information
I get a default nginx page when I set the root directory to "/usr/share/nginx/html/" in nginx.conf file, so the server is working ok.