Password Protecting Directories With Nginx

Nginx-logo The first thing you will need to do is create a file called .htpasswd (it doesn’t have to be named that way). The following command creates a new .htpasswd file and stores a record in it for user tom.

htpasswd -bc /var/www/yourdomain.com/.htpasswd tom password

To create another user:

htpasswd -b /var/www/yourdomain.com/.htpasswd john password

Read morePassword Protecting Directories With Nginx

Nginx virtual host – Nginx server block

ngin xvirtual host | nginx server block

We’ll show you how to create an Nginx Virtual Host, also known as an Nginx Server Block. In one of our previous tutorials we explained How to install and configure LNMP (Nginx, MySQL and PHP) server on a Debian 6 (squeeze) VPS, now we’re going to look at how to set up a new server block (virtual host) for each new domain.

Read moreNginx virtual host – Nginx server block

How to install and configure LEMP (Nginx, MySQL and PHP) server on a Debian 6 (squeeze) VPS

Nginx MySQL and PHP on DebianVPSNginx is a free, open-source, high-performance HTTP server which unlike his ‘friends’, it does not rely on threaded handling of the requests but instead it uses a much more scalable event driven (asynchronous) architecture. This uses a very small and predictable amount of memory under heavy load. Nginx in combination with the simple and very robust FastCGI Process Manager for PHP (PHP-FPM) and the world most popular database server MySQL can give you a lot of power and performance while still using a small memory footprint.

The following article looks at how to install and configure this stack on one of our Debian based VPSes.

Read moreHow to install and configure LEMP (Nginx, MySQL and PHP) server on a Debian 6 (squeeze) VPS