Here’s How to Install the Nginx Web Server on Your Linux VPS
1. Go to the VPS panel and log in.
2. Click Manage on your desired (Linux) server.
3. Ensure your VPS is running and click the VNC logo.
4. Log in.
5. Begin by updating everything. Type: sudo apt update
6. Ensure the firewall is enabled. Type: sudo ufw enable
7. Now start installing Nginx. Do this by typing: sudo apt install nginx
8. During the installation, you will be asked: "Do you want to continue?" Type Y and press the ENTER key.
9. During the installation, Nginx is automatically added to ufw. To list applications that work with ufw, type: sudo ufw app list
10. The output should look like this:
Nginx Full: All ports open (80 and 443).
Nginx HTTP: Only port 80 open.
Nginx HTTPS: Only port 443 open.
11. Now, open the firewall. It is recommended to only open the port you need. For us, this will be port 80. So we type: sudo ufw allow 'Nginx HTTP'
12. To check if this was successful, type: sudo ufw status
13. The output should look like this:
14. Nginx is now installed. You can confirm this by typing: systemctl status nginx. It should display active.