Infrastructure of Anulu

When I started to build this portal I wanted to learn something new. Because of that I choosed JAM stack and Gatsby. For the analytics I wanted to use a self hosted tool, beacuse of don't want to share my data with big tech companies and I choosed matomo (new name of piwik). They are behind an ngingx reverse proxy, and they are running in docker containers.


Infrastracture

Docker

Docker

Docker is a set of platform of service products (PaaS) that use OS-level virtualization. For my point of view docker is a very important part of the SW development, because the developers can test the application in the same environment like the prod environment. It means less unexpected behavior in prod. :) An another advantage, that the developers shouldn't install any dependency on the host machine, because the dependencies could be a part of the docker images, or in the case of the services, the docker containers can communicate with each other. In this case the developers can choose between docker-compose, docker swarm, k8s and openshift platforms. The docker overhead is very small.

Matomo

Matomo is an analytics tool to follow the usage of the web sites. It is possible to check the used devices (OS, screen resolution), the visitors locations and so on.

Matomo

Mysql

Matomo needs a database. In this case I choosed MySQL to store the analytics data.

Gatsby.js

Gatsby is an open source frontend framework. Its main advantages are:

  • better performance
  • higher security
  • cheaper, easier scaling

Nginx

Nginx is a very popular and super fast open source web server. In the case of anulu nginx redirects the requests either to an anouther docker container, which executes another nginx instance to reach anulu portal, or it is redirects the requests to the matomo. The commincation is encrypted with ACME, to generate the renewable Let's Encrypt certificates for matomo and for anulu.