Articles about Nginx

Nginx is a powerful web server that can serve as a reverse proxy server.

In this page, you will find articles relating to Nginx. Topics include installing and configuring Nginx on different computing platforms (including Raspberry Pi).

How to setup a reverse proxy server with nginx, Raspian Jessie Lite and Raspberry Pi 3

If you plan to deploy multiple devices at home and made them publicly accessible from outside your home network, you may want to consider setting up a reverse proxy server that will route HTTP traffic from the internet to the respective devices residing in your home network.

Tagged with an affordable price tag with good specifications, the Raspberry Pi 3 is an ideal candidate for the hardware of a reverse proxy server at home. And since the nginx server is a powerful reverse proxy server that can run efficiently on commodity hardware, it is an ideal candidate for the software aspect of a reverse proxy server.

This post documents how to setup a reverse proxy server with nginx, Raspian Jessie Lite and Raspberry Pi 3.

The reverse proxy server

With the proliferation of cloud computing and single board computers, the term – reverse proxy server, becomes a frequent mention in technical specifications that we may encounter as a developer or system implementation consultant.

Finding myself having to reiterate my understanding of the reverse proxy server, I reckoned that I should document what I know about the reverse proxy server so that I have a place where people can reference when they are lost with the topic of reverse proxy server.

How I setup a CCTV camera with Raspberry Pi Zero W and motionEyeOS image for home surveillance

When the Raspberry Pi Zero W was launched, I didn’t think twice before ordering one. Compared to the Raspberry Pi Zero, the Raspberry Pi Zero W comes with WiFi. This meant that I can use my new Raspberry Pi Zero W to replace my Raspberry Pi 3 CCTV camera for home surveillance and use the more powerful Raspberry Pi 3 for other projects.

This post documents how I setup my Raspberry Pi Zero W as a CCTV camera using the MotionEyeOS image.

How I setup Codiad web IDE on my Raspberry Pi 3 with Ubuntu Server 15.10.3, Nginx and PHP

There are times when I get the urge to work on project source codes that reside on my Raspberry Pi 3 LEMP server while I am on the move. Setting up a web based IDE on my Raspberry Pi 3 is one way to enable me to code while I am on the move, so long as I have a device with a web browser that is connected to the internet. Since I had already setup a LEMP server to run WordPress on my Raspberry Pi 3 and that Codiad is written in PHP, Codiad is an ideal web based IDE that I can set up on my Raspberry Pi 3.

This post documents how I setup Codiad web IDE on my Raspberry Pi 3. To make this post complete, I had taken some of the steps mentioned in my other posts on Raspberry Pi and replicated it in this post.

Setting up Nginx server on Windows 10

Recently, I got my wife an Asus ROG GL552VW-DH74 15-Inch Gaming laptop as a development machine (so that I can have a machine to use when I feel like gaming). Since the nginx server is one of my favorite servers for building web applications, it is something that I will always setup first when I get a new development machine.

I will set up my nginx server to listen on port 80 and serve as a reverse proxy to web applications listening on other port numbers. And since the ROG GL552VW-DH74 15-Inch Gaming laptop came with Windows 10, this post documents the steps that I went through to set up nginx server on Windows 10.

The Nginx configurations that I had created to serve only robots.txt and sitemap-index.xml over http

I had initially configured a set of Nginx rules that will redirect every single request made over http to https. However, that breaks my doing so breaks my reference on how to send HTTP GET request with Java without using any external libraries.

Since the robots.txt is not sensitive data, I had decided to allow it to be retrieved via http as well. And since my robots.txt points to sitemap-index.xml via http, I also allowed sitemap-index.xml to be retrieved via http as well.

This post documents the changes that I had made to my Nginx configurations to serve only robots.txt and sitemap-index.xml over the http protocol.

Setting up a free CA signed SSL certificate from Let’s Encrypt for my LEMP server on my Raspberry Pi 3 with an Ubuntu Server 15.10.3 image to secure my WordPress site

After setting up a LEMP web server on Raspberry Pi 3 with an Ubuntu Server 15.10.3 image to host my new WordPress website, a good colleague of mine recommended me to try implementing a free certified SSL certificate. The intelligent and generous folks from Let’s Encrypt had created a free and open Certificate Authority and an automated workflow for websites to generate certified SSL certificates for serving trusted and encrypted communication.

Since, there is no cost involved in implementing the SSL certificate, I went on to try and implement one on the Nginx server on my Raspberry Pi 3.

This post documents my process on setting up a Let’s Encrypt certified SSL certificate for my Nginx server on my Raspberry Pi 3.

Setting up a LEMP web server on Raspberry Pi 3 with an Ubuntu Server 15.10.3 image to host a WordPress website

I was trying to start a new WordPress site. Before hosting it on a Digital Ocean droplet, I decided to incubate the WordPress site on a Raspberry Pi 3 to clock some content. This post documents the steps that I took to set up a LEMP web server on Raspberry Pi 3 with an Ubuntu server 15.10.3 image to host a new WordPress site.

Preventing image hotlinking with Nginx, with some style

Image hotlinking is a situation when your image appears on other website(s) but that image was actually being served by your web server. Image hotlinking is bad; your image gets stolen from your website and your server resources is being spent to serve them. If you happen to be running Nginx as your web server, this post describes how you can use Nginx to prevent image hotlinking with a smarter way that was suggested by Hongkiat.