diff --git a/guide/english/nginx/index.md b/guide/english/nginx/index.md index 81eb54dcc6..3694c333c0 100644 --- a/guide/english/nginx/index.md +++ b/guide/english/nginx/index.md @@ -1,25 +1,38 @@ --- -title: Installation of Nginx in Ubuntu +title: Nginx --- +# Nginx + ## Introduction - - Nginx is a web server which can also be used as a reverse proxy, load balancer and HTTP cache. - It is one of the most popular web servers in use and is responsible for hosting some of the largest and highest-traffic sites on the internet. - It is proven to be lighter on resources than httpd/Apache. - Nginx is free and open-source software, first released in 2004. -## Installation of Nginx on Ubuntu +## Installation + +### Installation of Nginx on Ubuntu Update the local package index and install Nginx from default repositories: ```sh -$ sudo apt update -$ sudo apt install nginx -$ sudo systemctl status nginx # will check if the server is running as the installation should have started it already +$ sudo apt-get update && sudo apt-get upgrade +$ sudo apt-get install nginx +$ sudo systemctl status nginx ``` -## Installation of Nginx on CentOS 7 +Enable nginx on the firewall using `ufw` +```sh +sudo ufw allow 'Nginx HTTP' +``` + +Validate nginx is running: +```sh +systemctl status nginx +``` + +### Installation of Nginx on CentOS 7 Add Nginx repository and install: @@ -49,7 +62,6 @@ $ sudo systemctl start nginx # will start the server #### More Information - [An Introduction to NGINX for Developers](https://medium.freecodecamp.org/an-introduction-to-nginx-for-developers-62179b6a458f) [Nginx tutorial](https://www.netguru.co/codestories/nginx-tutorial-basics-concepts) [Links to top tutorials](https://medium.com/quick-code/top-tutorials-to-learn-nginx-for-web-server-dc8638c48fae)