Docker enables us to avoid the ‘its working on my machine’ pit-hole. It packages our application into a sort of box or in other words, container. You can easily run this container in any machine with its contents, i.e environments intact.
This beginners guide aims to assist you in building and deploying a simple Node.js application image. This guide also assumes you have some basic knowledge of node and express framework. You also need to have docker installed on your machine.
To create a node app run the command below
npm init
The command above will walk you through setting up a node application. For beginners, you can choose to press enter after every choice to have the default setup. You can also choose to have your entry point as index.js or app.js. The entry point is where your app will start.
#docker-image #node #node-js-tutorial #docker #nodejs