Skip to content
Orhan

NGINX

Tutorial, nginx, udemy1 min read

Disclaimer: This may not cover all the content. They are just notes I found important to remember

Building Nginx from Source for Ubuntu

  • Go to http://nginx.org/en/download.html

  • Select the stable version

  • on terminal use wget to download the source code

  • untar the nginx source code

    • $ tar -zxvf nginx-1.18.0.tar.gz
    • then go into untared directory
  • then go to terminal and type ./configure

    • if you have configuration errors, you might be missing build-essentials
    • if you are missing modules, then apt-get install [module]
    • for example apt-get install libpcre3 libpcre3-dev zlib1g zlib1g-dev libssl-dev
  • $ ./configure --sbin-path=/usr/bin/nginx --conf-path=/etc/nginx/nginx.conf --error-log-path=/var/log/nginx/error.log --http-log-path=/var/log/nginx/access.log --with-pcre --pid-path=/var/run/nginx.pid --with-http_ssl_module

  • $ make

    • this will compile the application
  • $ make install

    • this will install nginx
  • type $ nginx or $ sudo nginx to start nginx

  • go to localhost or 127.0.0.1 to see welcome to nginx start page or just simply check on terminal $ ps aux | grep nginx