What's New

Configuring a Virtual Host in NGINX

Getting Started with NGINX

Configuring a virtual host in NGINX is the first step into creating a website to publish to the world. Server Blocks, often referred as NGINX virtual host are a feature of the NGINX web server that allows you to host multiple websites on one server. 

The virtual host configuration file normally contains a server function (server block) with { }. Inside the { } will contain the information needed to run your website.

When creating your virtual host configuration file you will always need to declare a root folder in which your website is going to be hosted inside the server. This can be done by using mkdir command to create your directory. Typically, all websites are placed inside /var/www directory.

Once you create your directory to host your website files into. Create a basic index.html file and load it up within your browser to make sure the site is up and running.

For a complete break down on how to configure virtual host within NGINX make sure to view the video.

About BjTechNews (1013 Articles)
An IT guy trying to learn everything about technology and sharing it with you all. I'm a blogger and video blogger who highlights daily news in the tech industry, promoting tips and hacks for fellow techies.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: