Docker Agent
The Docker based agent collects and streams metrics, traces and logs to Middleware for further analysis. The agent runs as a sidecar and is simple to deploy as a daemonset or with docker compose.
This guide is a quick start for Docker. See the Docker documentation for more configuration options.
Installing the Agent
The required MW_API_KEY
and MW_TARGET
will be pre-filled if you've logged into our docs, and are accessible in the Platform's Installation Pages.
1MW_API_KEY="<MW_API_KEY>" MW_TARGET=https://<MW_UID>.middleware.io:443 bash -c "$(curl -L https://install.middleware.io/scripts/docker-install.sh)"
1version: "3.8"
2services:
3 mw-host-agent:
4 image: ghcr.io/middleware-labs/mw-host-agent:master
5 environment:
6 - MW_API_KEY=<MW_API_KEY>
7 - MW_TARGET=https://<MW_UID>.middleware.io:443
8 ports:
9 - 9319:9319
10 - 9320:9320
11 - 8006:8006
12 volumes:
13 - /var/run/docker.sock:/var/run/docker.sock
14 - /var/log:/var/log
15 - /var/lib/docker/containers:/var/lib/docker/containers
16 - /tmp:/tmp
17 privileged: true
18 network_mode: host
Verify Installation
Run the following command to verify the Infra Agent status:
1docker ps -a --filter ancestor=ghcr.io/middleware-labs/mw-host-agent:master
If status is UP
or Exited
, the installation was successful. If status is blank, installation was unsuccessful.
Infrastructure Dashboard
Middleware takes a few minutes to index new data sets. Once all attributes have been indexed all data will be accessible in the platform on the Infrastructure page, in the Dashboard Builder, and when building Alerts.