sudo apt-get update
sudo apt-get install nginx
server {
listen 80;
server_name your_domain.com www.your_domain.com;
location / {
root /path/to/your/website;
index index.html;
}
}
bash
sudo ln -s /etc/nginx/sites-available/your_website_config /etc/nginx/sites-enabled/
bash
sudo nginx -t
sudo service nginx restart
Ensure that Nginx is running:
sudo service nginx status