Skip to content

Instantly share code, notes, and snippets.

@bakins bakins/datadog.diff
Created Dec 9, 2015

Embed
What would you like to do?
datadog 5.6.2 patch
diff --git a/utils/dockerutil.py b/utils/dockerutil.py
index 975b260..d8e0868 100644
--- a/utils/dockerutil.py
+++ b/utils/dockerutil.py
@@ -82,6 +82,7 @@ def find_cgroup_filename_pattern(mountpoints, container_id):
stat_file_path_coreos = os.path.join(mountpoint, "system.slice")
stat_file_path_kubernetes = os.path.join(mountpoint, container_id)
stat_file_path_kubernetes_docker = os.path.join(mountpoint, "system", "docker", container_id)
+ stat_file_path_docker_daemon = os.path.join(mountpoint, "docker-daemon", "docker", container_id)
if os.path.exists(stat_file_path_lxc):
return os.path.join('%(mountpoint)s/lxc/%(id)s/%(file)s')
@@ -93,5 +94,7 @@ def find_cgroup_filename_pattern(mountpoints, container_id):
return os.path.join('%(mountpoint)s/%(id)s/%(file)s')
elif os.path.exists(stat_file_path_kubernetes_docker):
return os.path.join('%(mountpoint)s/system/docker/%(id)s/%(file)s')
+ elif os.path.exists(stat_file_path_docker_daemon):
+ return os.path.join('%(mountpoint)s/docker-daemon/docker/%(id)s/%(file)s')
raise MountException("Cannot find Docker cgroup directory. Be sure your system is supported.")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.