From 988953047cc428c5d2592751dd19ce91868dd5b1 Mon Sep 17 00:00:00 2001 From: Julien Lebot Date: Thu, 30 Dec 2021 15:30:34 +0100 Subject: [PATCH 1/3] Update default.rb --- attributes/default.rb | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/attributes/default.rb b/attributes/default.rb index 6ef1c7dd..d83406a4 100644 --- a/attributes/default.rb +++ b/attributes/default.rb @@ -369,7 +369,12 @@ # the NPM module of system probe will still run. default['datadog']['system_probe']['enabled'] = false # sysprobe_socket defines the unix socket location -default['datadog']['system_probe']['sysprobe_socket'] = '/opt/datadog-agent/run/sysprobe.sock' +if platform_family?('windows') + default['datadog']['system_probe']['sysprobe_socket'] = 'localhost:3333' +else + default['datadog']['system_probe']['sysprobe_socket'] = '/opt/datadog-agent/run/sysprobe.sock' +end + # debug_port is the http port for expvar, it is disabled if set to 0 default['datadog']['system_probe']['debug_port'] = 0 default['datadog']['system_probe']['bpf_debug'] = false From d3899ca500949a08c86291457199eb0456dce4d3 Mon Sep 17 00:00:00 2001 From: Julien Lebot Date: Thu, 30 Dec 2021 16:35:30 +0100 Subject: [PATCH 2/3] Fix style offense --- attributes/default.rb | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/attributes/default.rb b/attributes/default.rb index d83406a4..80fcb21d 100644 --- a/attributes/default.rb +++ b/attributes/default.rb @@ -369,11 +369,14 @@ # the NPM module of system probe will still run. default['datadog']['system_probe']['enabled'] = false # sysprobe_socket defines the unix socket location -if platform_family?('windows') - default['datadog']['system_probe']['sysprobe_socket'] = 'localhost:3333' -else - default['datadog']['system_probe']['sysprobe_socket'] = '/opt/datadog-agent/run/sysprobe.sock' -end +default['datadog']['system_probe']['sysprobe_socket'] = + if platform_family?('windows') + # might be //opt/datadog-agent/run/sysprobe.sock + # note the // + 'localhost:3333' + else + '/opt/datadog-agent/run/sysprobe.sock' + end # debug_port is the http port for expvar, it is disabled if set to 0 default['datadog']['system_probe']['debug_port'] = 0 From 23d350f7c945f85f51f740dbb494a6a7e6e1b0c4 Mon Sep 17 00:00:00 2001 From: Julien Lebot Date: Tue, 4 Jan 2022 10:03:11 +0100 Subject: [PATCH 3/3] Address review comments --- attributes/default.rb | 2 -- 1 file changed, 2 deletions(-) diff --git a/attributes/default.rb b/attributes/default.rb index 80fcb21d..5fdf62af 100644 --- a/attributes/default.rb +++ b/attributes/default.rb @@ -371,8 +371,6 @@ # sysprobe_socket defines the unix socket location default['datadog']['system_probe']['sysprobe_socket'] = if platform_family?('windows') - # might be //opt/datadog-agent/run/sysprobe.sock - # note the // 'localhost:3333' else '/opt/datadog-agent/run/sysprobe.sock'