Since Ubuntu 21.10 has been released there was an immediate interest in using it as an OS Server. In this tutorial, we are going to see how to install Nginx on Ubuntu 21.10.
Prerequisites
- Ubuntu 21.10
- sudo privileges
Install the latest Nginx version on Ubuntu 21.10
Step 1. Get the latest packages with:
sudo apt update
Step 2. To install Nginx, run:
sudo apt install nginx
Step 3. Check version.
nginx -v
Output:
nginx version: nginx/1.18.0
Enable HTTP traffic
Step 1. Let’s see the application profiles.
sudo ufw app list
Output:
Available applications:
...
Nginx Full
Nginx HTTP
Nginx HTTPS
...
Step 2. Since we don’t have generated SSL/TLS certificate yet, we are going to allow HTTP traffic.
sudo ufw allow 'Nginx HTTP'
Step 3. Let’s check if the changes are here.
sudo ufw status
Output:
Status: active
To Action From
-- ------ ----
...
Nginx HTTP ALLOW Anywhere
...
Conclusion
The installation process is pretty simple and straightforward, so let us know if you need anything else. On a side note, follow our official channel on Telegram.