Making simple HTTP requests in NodeJS
Photo by Gabriel Heinzer on Unsplash

Of course there are numerous npm packages available to make HTTP requests. Just to name a few, you can use

and many more. These are all super fantastic libraries which bring in an array of capabilities on how to make HTTP request and handle various responses and errors.

But sometimes, all we need is, a simple HTTP/S request and response handler. This can be easily done with NodeJS’s built-in packages http / https with a very simple, lean piece of code. Lets see it in action.

NOTE: Since Promiseis fancy, so I am gonna use it…

As newer version of NodeJS is released, it brings with it — performance improvements, speed, security, new features and more. If you have a nodejs based web application and plan to upgrade the version of nodejs, then of course it becomes important to test the application on the new version to ensure its sanity.

In this post we will explore how can usewe Docker to run our nodejs based application with two (or more) versions of nodejs.

Lets explore the directory structure to understand how the files have been organized.

vishalr@ubuntu ~> tree multi-node-app
├── app
│ ├── index.js

As a web application developer, one of the most common challenge faced is, not having the local development environment close enough to the production environment. While there can be many aspects to this, in this post we will focus on the following two

Also, I am going to use docker for this demonstration. So lets begin.

I am going to use Wordpress as my example application. So lets head over the the docker page for Wordpress. …

Windows 10 Black & White mode

Very recently I bought myself, a Google Pixel 4A, a stylish & sleek mobile. I have always been a fan of the Pixel series since its launch.

A new feature which I found with Pixel 4A is, it allows you to set your sleep & wake up time. During this period, the phone turns to Do not disturb mode and more brilliant, the display turns an eye soothing Black & White mode. I am love with this.

Now, since I am a software engineer by profession and passion, I spend quite a lot of my time on my laptop. I…

Photo by Sebastian Herrmann on Unsplash

Containers have taken the world by the storm. Be it the application containers such as Docker or Rocket, or the operating system containers such as OpenVZ, LXC/LXD or Multipass.

I have always found containers pretty fascinating. The reason being that they provide with a neat & clean interface to start with and once you are done, all the mess can be cleaned up as if it was never there.

In this post we will have a look at Multipass which is an operating system containerzation technology by Canonical, the company behind Ubuntu. Multipass is available for Windows, Mac & Linux…

With availability of utilities such as create-react-app and create-react-library, setting up the barebones for a new react application development has become child’s play. But such utilites hide a lot of nitty gritty under their hood.

My idea of writing this post is, to allow new user learn how to start building a react application from scratch, without using any utility. Thus I created an empty application at react-from-scratch. The documentation mentions the step for application setup. The latter part of the document describes in brief about how the project has been setup.

Originally published at on October 14, 2020.

As programmer, I often juggle between multiple computer systems, for various purpose. Personally, I own a Macbook Air, a Linux desktop and a Windows laptop from my office. Quite often I am juggling between all the three machines, moving my hands from one keyboard to another, a tedious and boring task. So I was googling for how to share single keyboard & mouse across devices. There were several paid solutions, but I was looking for a free and open source solution. That’s when I found out BARRIER.

The fantastic part about BARRIER is that it is available for Linux, Mac…

Photo by Kari Shea on Unsplash

I have been using QwikLabs for quite a while for practicing the google cloud courses online. Now the thing with Google Cloud is that it provides everything inside the browser only, even the terminal access, called as console. But I wanted to be able to access the Google Cloud console from my local terminal for the ease of typing and personal habit of comfort in using the terminal.

I wasn’t sure if that was possible, since the Google Cloud console authorizes you for every action, implicitly, without you even realizing. So I googled a bit and found that Google Cloud…

Photo by Moritz Kindler on Unsplash

Similar to docker and rkt, LXD (pronounced Lex-dee) is also relatively new container orchestration engine. The first version LXD 0.1 was release on Feb 2015 and the latest version, 3.17, has been in September 2019 (See LXD release notes). Today we will peek into the basics of LXD and how it works.

As I mentioned earlier, LXD is a container orchestration engine. But mind it that, it is quite different from Docker. While docker containers are built for application containerization, LXD containers can run only Linux operating systems. It may seem like the the LXD containers are similar to virtual…

Photo by frank mckenna on Unsplash

This article is about learning a bit of docker & containers, running MySQL in docker containers and setting up various types of MySQL replications using docker containers.

So what is Docker? Docker is an open source tool which allow you to package your application and all of its dependencies into a single package and run it ubiquitously without any discrimination based on hardware or host operating system. The docker containers are like a virtual machine, but are smaller in size and consume lesser resource. For details see

So whats the benefit of running your application as docker container? Simple…

Vishal Raj

Software developer by Heart…

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store