Showing posts with label Nginx. Show all posts
Showing posts with label Nginx. Show all posts

Sunday, July 5, 2015

How To Install an SSL Certificate from a Commercial Certificate Authority

How To Install an SSL Certificate from a Commercial Certificate Authority


Introduction

This tutorial will show you how to acquire and install an SSL certificate from a trusted, commercial Certificate Authority (CA). SSL certificates allow web servers to encrypt their traffic, and also offer a mechanism to validate server identities to their visitors. The main benefit of using a purchased SSL certificate from a trusted CA, over self-signed certificates, is that your site's visitors will not be presented with a scary warning about not being able to verify your site's identity.

Friday, July 3, 2015

Understanding the Nginx Configuration File Structure and Configuration Contexts

Understanding the Nginx Configuration File Structure and Configuration Contexts


Introduction

Nginx is a high performance web server that is responsible for handling the load of some of the largest sites on the internet. It is especially good at handling many concurrent connections and excels at serving static content.

Thursday, July 2, 2015

Understanding Nginx HTTP Proxying, Load Balancing, Buffering, and Caching

Understanding Nginx HTTP Proxying, Load Balancing, Buffering, and Caching


Introduction

In this guide, we will discuss Nginx's http proxying capabilities, which allow Nginx to pass requests off to backend http servers for further processing. Nginx is often set up as a reverse proxy solution to help scale out infrastructure or to pass requests to other servers that are not designed to handle large client loads.
Along the way, we will discuss how to scale out using Nginx's built-in load balancing capabilities. We will also explore buffering and caching to improve the performance of proxying operations for clients.

How To Install Linux, nginx, MySQL, PHP (LEMP) stack on Ubuntu 14.04

Introduction

The LEMP software stack is a group of software that can be used to serve dynamic web pages and web applications. This is an acronym that describes a Linux operating system, with an Nginx web server. The backend data is stored in MySQL and the dynamic processing is handled by PHP.
In this guide, we will demonstrate how to install a LEMP stack on an Ubuntu 14.04 server. The Ubuntu operating system takes care of the first requirement. We will describe how to get the rest of the components up and running.

How To Set Up Nginx Server Blocks (Virtual Hosts) on Ubuntu 14.04 LTS

Introduction

When using the Nginx web server, server blocks (similar to the virtual hosts in Apache) can be used to encapsulate configuration details and host more than one domain off of a single server.
In this guide, we'll discuss how to configure server blocks in Nginx on an Ubuntu 14.04 server.

Wednesday, January 1, 2014

Nginx: Redirect Backend Traffic Based Upon Client IP Address

I have four Apache backend servers in front of nginx reverse proxy server. How do I make sure nginx reverse proxy load balancer always send specific client IP address (say IP 1.2.3.4) request to http://apachereadwrite/ backend and rest to http://apachereadonly/ backend?

Nginx web server does support if conditionalconfiguration. You can redirect and/or select configuration depending on client ip address. In this case you need to use the variable called $remote_addr which can be used to retrieve information about the users ip address. This is useful if you want to give file upload capabilities to your own office IP address and read-only capabilities to the rest of the world based upon client IP address or vpn address:

Sunday, December 1, 2013

HowTo: Enable Nginx Status Page

Apache has status page that can provide data about Apache. How do I enable and display such page using nginx server? How do I enable nginx status page on Linux or Unix-like operating systems?

Like Aapache (httpd), nginx has status page to give you information about Nginx's server health including Active connections and other data. You can use this info to fine tune your server. Please note that you will get stats for entire Nginx server running. This can not be used to get info per virtual host i.e. you will get data for entire Nginx server only.