Datadog Docker Agent with BTRFS support and monitoring of other Docker Nginx status pages.
Note: Docker networking has undergone a lot of development since this setup was written.
There may be other more elegant methods of adjusting the nginx.yaml files that with the /etc/hosts mapping.
You'll need to find a way to make sure this is supervised.
Run the Datadog Docker Agent with the /tmp/.containerIPs.log mapped into the agent container. In CoresOS, the systemd Unit file, the ExecStart will look like:
ExecStart=/usr/bin/bash -c
"/usr/bin/docker run -p 8125:8125/udp --privileged --name dd-agent.%i -h hostname
-v /var/run/docker.sock:/var/run/docker.sock
-v /proc/mounts:/host/proc/mounts:ro
-v /sys/fs/cgroup/:/host/sys/fs/cgroup:ro \
-v /tmp/.containerIPs.log:/tmp/.containerIPs.log:ro \
-e API_KEY=etcdctl get /ddapikey
yourdockerrepo/docker-dd-agent"
Modify nginx.conf in your related Docker containers to enable status page to the local network/host: Add a new server block to the Nginx.conf file with the following - make sure to specify a different listening port than port 80, e.g. 8802:
server { listen 8802;
location /nginx_status {
stub_status on;
access_log off;
allow 172.17.0.0/16;
deny all;
}
}
In nginx_yamler.sh in the Datadog Docker containers (before build), make sure you're using the same port as in the server block above, e.g. 8802
Enable the Nginx Status monitoring in the Docker Monitoring Dashboard's Integration settings, if it is not already enabled.
For more information about the metric collected, please see here: http://wiki.nginx.org/HttpStubStatusModule and http://docs.datadoghq.com/integrations/nginx/
Content type
Image
Digest
Size
109.7 MB
Last updated
almost 10 years ago
docker pull techakcent/datadog-docker-agent-nginx