node.js, domino-db & Docker (5): memcached 

By Sven Hasselbach | 11/5/18 3:04 AM | App Dev - Web | Added by Oliver Busse

To use memcached in our Docker container, we have to modify the existing Dockerfile a little bit. First it is required to install memcached in the container itself, and then it is required to change the CMD command to start the service and our express application.

node.js, domino-db & Docker (4): Error Handling 

By Sven Hasselbach | 11/1/18 11:03 AM | App Dev - Web | Added by Oliver Busse

When we started our express application and accessed it in the browser, an error raised on the console and no response was sent back to the browser. The reason for this behaviour is that the database connection is not correctly configured, and the request from our application fails.

node.js, domino-db & Docker (3): Adding domino-db 

By Sven Hasselbach | 11/1/18 3:46 AM | App Dev - Web | Added by Oliver Busse

The express application is still the boilerplate created by express generator. Now let’s look into the existing code and use the domino-db package. First we have to understand express a little bit better. I won’t go deeply into details, because there are many tutorials available, and the documentation is really awesome.

node.js, domino-db & Docker (2): Dev Environment 

By Sven Hasselbach | 11/1/18 3:45 AM | App Dev - Web | Added by Oliver Busse

Before we can start to create a new app we first have to setup a development environment. While there are multiple IDE’s around, I have made most of my node.js development with Atom instead of an IDE like Eclipse or Visual Studio. Maybe this will change in the future, but for a better understanding, let’s start with Atom and do the required steps manually.

node.js, domino-db & Docker 

By Sven Hasselbach | 11/1/18 3:45 AM | App Dev - Web | Added by Oliver Busse

Here is an example to create a express application with the new domino-db npm module and run it in a docker container. Requirements are that node.js & Docker is installed. Everything is done in the command line and a text editor.