I am using nginx to host a website and following is the current configuration which is defined at /etc/nginx/sites-available/mysite
Config
server {
listen 80;
root /var/www/mysite;
index.php index.htm index.html;
}
Problem is as soon as I set another page as default nginx start throwing error
unknown directive "somepage.php" in /etc/nginx/sites-enabled/mysite
New Config
server {
listen 80;
root /var/www/mysite;
somepage.php index.php index.htm index.html;
}
I don't understand what am I doing wrong here. Can you please check?
0 Answers