Nginx is one of the popular web servers used on the internet. Ngnix can be used as a web server or a reverse proxy.
- Install Nginx
- sudo apt-get update
- sudo apt-get install nginx
- Make changes to Firewall
- sudo ufw app list (to list apps)
- sudo ufw allow ‘Nginx HTTP’
- sudo ufw status
- Check the status
- systemctl status nginx
- Nginx Relates Files and Folders
- Web Content Location: /var/www/html
- Nginx Configuration File: /etc/nginx/nginx.conf
- Access Log: /var/log/nginx/access.log
- Error Log: /var/log/nginx/error.log
- Managing Nginx
- Stop: sudo systemctl stop nginx
- Start: sudo systemctl start nginx
- Restart: sudo systemctl restart nginx
- Reload Config Changes: sudo systemctl reload nginx
