Loading system logs into Loki
To get started, cd to the Chapter13 directory in your clone of this book’s repository.
To stand up a Loki logging pipeline, we’ll need to set up a series of services in Docker Compose. In our initial deployment, we will set up three services: loki, promtail, and grafana. By now, adding these services to a docker-compose.yml file should be familiar and straightforward.
Networking our services
Before we start up our services, we will want to establish a network that links them all together. All services started from a single docker-compose.yml file that shares a common network called myapp_default. We will not use the default name and instead define the network name for our service as loki. There is no requirement to do this, but it demonstrates how you can link up multiple services to not just one default network but potentially several in a more complex network topology.
This is how we will start off our docker-compose.yml file...