Sign inSign up

egbertp/dd-agent

By egbertp

•Updated over 11 years ago

DataDog agent

Image
0

1.0K

egbertp/dd-agent repository overview

⁠Datadog Agent Dockerfile

This repository is meant to build the base image for a Datadog Agent container. You will have to use the resulting image to configure and run the Agent.

This container is build from https://github.com/denniseijpe/docker-dd-agent⁠ with added support for network metrics. Thanks Dennis!

For more information, see: https://registry.hub.docker.com/u/datadog/docker-dd-agent/⁠

⁠Quick Start

The default image is ready-to-go. You just need to set your hostname and API_KEY in the environment.

docker run -d --name dd-agent -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 -e API_KEY={your_api_key_here} datadog/docker-dd-agent

⁠Service file (fleet)

[Unit]
Description=DataDog agent service

[Service]
Restart=always
TimeoutStartSec=20m
EnvironmentFile=/etc/environment
ExecStartPre=-/usr/bin/docker rm -f -v dd-agent
ExecStartPre=-/usr/bin/docker pull egbertp/dd-agent
ExecStart=/bin/sh -c "/usr/bin/docker run --privileged --net=host --name dd-agent -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 -e API_KEY=`etcdctl -C http://${COREOS_PRIVATE_IPV4}:4001 --no-sync get /ddapikey` egbertp/dd-agent"
ExecStop=/usr/bin/docker kill dd-agent

[X-Fleet]
Global=true

Set the DataDog API key into etcd

etcdctl set /ddapikey "<YOUR DATADOG API KEY>"

Tag summary

Content type

Image

Digest

sha256:68372175c…

Size

-

Last updated

over 11 years ago

docker pull egbertp/dd-agent