Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kitchen fixes #829

Closed
Closed
Changes from 1 commit
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
3342f68
add parameter data types, fix whitespacing, remove legacy facts, remo…
Dec 20, 2024
e2b9c25
update linting rules
Dec 20, 2024
373df1c
added missing data types, removed optional when we defaulting things.…
Dec 20, 2024
3153b49
add default extensions
Dec 20, 2024
f54b860
optional param should not be optional if using default. prettied things
Dec 20, 2024
84ed1a2
now that we support Puppet 8, we should support stdlib v9. add lintin…
Dec 20, 2024
bdd7245
upgrade pdk version to 3.4
Dec 23, 2024
9231147
controlling versions of io-console (as 0.8 is built for Ruby 3.3) and…
Dec 23, 2024
c9a36a0
update the reference to concat to support later versions of stdlib
Jan 24, 2025
57681d7
update to new stdlib function
Jan 27, 2025
3ae9a1f
fixes requested by code review
Jan 27, 2025
cd105ea
remove deprecated function, moving to is_a
Jan 27, 2025
9b4023d
version comparison is working with a int not a string
Jan 27, 2025
7ae4422
making optional following code review
Jan 27, 2025
20176f8
revert versioncmp changes made by pdk validate
Jan 27, 2025
169150c
removing linting check for use of versioning as we use integers for v…
Jan 27, 2025
0b53595
update module dependencies to support Puppet 8
Jan 28, 2025
04dbd40
fixed class documentation and made params optional
Jan 28, 2025
d718c77
fix all optional references to undef calls. fix warnings about no cla…
Jan 28, 2025
1868a80
fix for unless command
Jan 28, 2025
daa8e2d
fix pdk validation warnings
fanny-jiang Jan 28, 2025
3c260f0
made sitename required
Jan 28, 2025
526174e
making url required.
Jan 28, 2025
896f7d2
correcting default on min collection interval
Jan 28, 2025
c1f6034
making check name required.
Jan 28, 2025
be91e8f
making host required
Jan 28, 2025
c49198a
making port required
Jan 28, 2025
cc59363
fix gemfile for ruby < 3.1 and puppet 7; bump bundler to v2.4.13 in CI
fanny-jiang Jan 28, 2025
06d6a0b
Merge remote-tracking branch 'contributor/xenon8/puppet-8-upgrade' in…
fanny-jiang Jan 29, 2025
56efc7f
update deps
fanny-jiang Jan 29, 2025
bd64797
exclude EOL versions from CI
fanny-jiang Jan 29, 2025
0217ada
update gemfile.lock and .gitignore
fanny-jiang Jan 29, 2025
5795855
fix config
fanny-jiang Jan 30, 2025
2e312cd
update ci specs
fanny-jiang Jan 31, 2025
bf6d375
use ruby 2.6+ puppet 6.5+ in ci
fanny-jiang Jan 31, 2025
e948616
remove gemfile.lock before installing bundler
fanny-jiang Jan 31, 2025
6f21b9c
clean up circleci, update gemfile.lock
fanny-jiang Jan 31, 2025
ce70621
rm .vscode
fanny-jiang Jan 31, 2025
0bb30c7
use ruby 2.7+ puppet 6.5+ in ci
fanny-jiang Jan 31, 2025
d049045
update Gemfile.lock
fanny-jiang Jan 31, 2025
b774e19
debug bundler version
fanny-jiang Jan 31, 2025
9e4ac83
add linux deps for ci
fanny-jiang Jan 31, 2025
b47a62b
config.yml cleanup
fanny-jiang Jan 31, 2025
103532a
update kitchen.yml
fanny-jiang Jan 31, 2025
7807455
install ruby 2.6 for centos
fanny-jiang Jan 31, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
revert versioncmp changes made by pdk validate
Darren Gipson committed Jan 27, 2025
commit 20176f8aeba769fe29925d13f4893c04b4f43ef7
12 changes: 0 additions & 12 deletions manifests/init.pp
Original file line number Diff line number Diff line change
@@ -410,10 +410,7 @@
if $facts['os']['release']['full'] =~ /^6(.[0-9])?/ and $agent_version == 'latest' {
notice("datadog-agent ${_agent_major_version}.51 is the last supported version on CentOS 6. Installing ${_agent_major_version}.51 now")
$agent_full_version='7.51.1'
# $_agent_minor_version is a Integer, so we can't use the versioncmp function
# lint:ignore:version_comparison
} elsif $facts['os']['release']['full'] =~ /^6(.[0-9])?/ and $_agent_minor_version != undef and $_agent_minor_version > 51 {
# lint:endignore
fail("datadog-agent ${_agent_major_version}.51 is the last supported version on CentOS 6.")
} else {
$agent_full_version = $agent_version
@@ -422,12 +419,9 @@
default: { $agent_full_version = $agent_version }
}

# $_agent_major_version is a Integer, so we can't use the versioncmp function
# lint:ignore:version_comparison
if $_agent_major_version != 5 and $_agent_major_version != 6 and $_agent_major_version != 7 {
fail("agent_major_version must be either 5, 6 or 7, not ${_agent_major_version}")
}
# lint:endignore

if ($facts['os']['name'] == 'Windows' and $windows_ddagentuser_name != undef) {
$dd_user = $windows_ddagentuser_name
@@ -436,10 +430,7 @@
}

if $conf_dir == undef {
# $_agent_major_version is a Integer, so we can't use the versioncmp function
# lint:ignore:version_comparison
if $_agent_major_version == 5 {
# lint:endignore
$_conf_dir = $datadog_agent::params::legacy_conf_dir
} else {
$_conf_dir = $datadog_agent::params::conf_dir
@@ -663,10 +654,7 @@
}
}

# $_agent_major_version is a Integer, so we can't use the versioncmp function
# lint:ignore:version_comparison
if $_agent_major_version == 5 {
# lint:endignore
if ($facts['os']['name'] == 'Windows') {
fail('Installation of agent 5 with puppet is not supported on Windows')
}
2 changes: 1 addition & 1 deletion manifests/integration.pp
Original file line number Diff line number Diff line change
@@ -10,7 +10,7 @@
# datadog_agent class, causing a dependency cycle. If using this class
# directly, you should define datadog_agent before datadog_agent::integration.

if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/${integration}.d"
$dst = "${dst_dir}/${$conf_file}.yaml"
if (! defined(File[$dst_dir])) {
2 changes: 1 addition & 1 deletion manifests/integrations/activemq_xml.pp
Original file line number Diff line number Diff line change
@@ -55,7 +55,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/activemq_xml.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/activemq_xml.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/apache.pp
Original file line number Diff line number Diff line change
@@ -36,7 +36,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/apache.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/apache.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/cacti.pp
Original file line number Diff line number Diff line change
@@ -21,7 +21,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/cacti.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/cacti.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/cassandra.pp
Original file line number Diff line number Diff line change
@@ -39,7 +39,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/cassandra.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/cassandra.d"

file { $legacy_dst:
2 changes: 1 addition & 1 deletion manifests/integrations/ceph.pp
Original file line number Diff line number Diff line change
@@ -24,7 +24,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/ceph.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/ceph.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/consul.pp
Original file line number Diff line number Diff line change
@@ -36,7 +36,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/consul.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/consul.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/directory.pp
Original file line number Diff line number Diff line change
@@ -89,7 +89,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/directory.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/directory.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/disk.pp
Original file line number Diff line number Diff line change
@@ -90,7 +90,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/disk.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/disk.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/dns_check.pp
Original file line number Diff line number Diff line change
@@ -36,7 +36,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/dns_check.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/dns_check.d"
file { $legacy_dst:
ensure => 'absent',
4 changes: 2 additions & 2 deletions manifests/integrations/docker_daemon.pp
Original file line number Diff line number Diff line change
@@ -64,7 +64,7 @@
notify => Service[$datadog_agent::params::service_name],
}

if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$legacy_dir = "${datadog_agent::params::conf_dir}/docker_daemon.d"

file { $legacy_dir:
@@ -84,7 +84,7 @@
ensure => 'absent',
}

if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/docker.d"

file { $dst_dir:
2 changes: 1 addition & 1 deletion manifests/integrations/elasticsearch.pp
Original file line number Diff line number Diff line change
@@ -66,7 +66,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/elastic.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/elastic.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/fluentd.pp
Original file line number Diff line number Diff line change
@@ -24,7 +24,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/fluentd.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/fluentd.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/generic.pp
Original file line number Diff line number Diff line change
@@ -24,7 +24,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/${integration_name}.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/${integration_name}.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/haproxy.pp
Original file line number Diff line number Diff line change
@@ -37,7 +37,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/haproxy.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/haproxy.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/http_check.pp
Original file line number Diff line number Diff line change
@@ -239,7 +239,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/http_check.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/http_check.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/jenkins.pp
Original file line number Diff line number Diff line change
@@ -19,7 +19,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/jenkins.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/jenkins.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/jmx.pp
Original file line number Diff line number Diff line change
@@ -68,7 +68,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/jmx.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/jmx.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/kafka.pp
Original file line number Diff line number Diff line change
@@ -87,7 +87,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/kafka.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/kafka.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/kong.pp
Original file line number Diff line number Diff line change
@@ -35,7 +35,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/kong.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/kong.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/kubernetes.pp
Original file line number Diff line number Diff line change
@@ -33,7 +33,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/kubernetes.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/kubernetes.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/kubernetes_state.pp
Original file line number Diff line number Diff line change
@@ -25,7 +25,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/kubernetes_state.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/kubernetes_state.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/linux_proc_extras.pp
Original file line number Diff line number Diff line change
@@ -19,7 +19,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/linux_proc_extras.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/linux_proc_extras.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/logs.pp
Original file line number Diff line number Diff line change
@@ -39,7 +39,7 @@
class datadog_agent::integrations::logs (
Array $logs = [],
) inherits datadog_agent::params {
unless versioncmp($datadog_agent::_agent_major_version, '5') == 0 {
unless $datadog_agent::_agent_major_version == 5 {
require datadog_agent

file { "${datadog_agent::params::conf_dir}/logs.yaml":
2 changes: 1 addition & 1 deletion manifests/integrations/marathon.pp
Original file line number Diff line number Diff line change
@@ -19,7 +19,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/marathon.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/marathon.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/memcache.pp
Original file line number Diff line number Diff line change
@@ -55,7 +55,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/mcache.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/mcache.d"
file { $legacy_dst:
ensure => 'absent',
4 changes: 2 additions & 2 deletions manifests/integrations/mesos_master.pp
Original file line number Diff line number Diff line change
@@ -18,7 +18,7 @@
) inherits datadog_agent::params {
require datadog_agent

if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/mesos.d"

file { $dst_dir:
@@ -39,7 +39,7 @@
}

$legacy_dst_master = "${datadog_agent::params::legacy_conf_dir}/mesos_master.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_master_dir = "${datadog_agent::params::conf_dir}/mesos_master.d"
file { $legacy_dst_master:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/mesos_slave.pp
Original file line number Diff line number Diff line change
@@ -17,7 +17,7 @@
String $url = 'http://localhost:5051'
) inherits datadog_agent::params {
$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/mesos_slave.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/mesos_slave.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/mongo.pp
Original file line number Diff line number Diff line change
@@ -99,7 +99,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/mongo.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/mongo.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/mysql.pp
Original file line number Diff line number Diff line change
@@ -117,7 +117,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/mysql.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/mysql.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/network.pp
Original file line number Diff line number Diff line change
@@ -42,7 +42,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/network.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/network.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/nginx.pp
Original file line number Diff line number Diff line change
@@ -66,7 +66,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/nginx.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/nginx.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/ntp.pp
Original file line number Diff line number Diff line change
@@ -33,7 +33,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/ntp.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/ntp.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/pgbouncer.pp
Original file line number Diff line number Diff line change
@@ -54,7 +54,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/pgbouncer.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/pgbouncer.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/php_fpm.pp
Original file line number Diff line number Diff line change
@@ -51,7 +51,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/php_fpm.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/php_fpm.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/postfix.pp
Original file line number Diff line number Diff line change
@@ -49,7 +49,7 @@
}

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/postfix.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/postfix.d"
file { $legacy_dst:
ensure => 'absent',
2 changes: 1 addition & 1 deletion manifests/integrations/postgres.pp
Original file line number Diff line number Diff line change
@@ -103,7 +103,7 @@
require datadog_agent

$legacy_dst = "${datadog_agent::params::legacy_conf_dir}/postgres.yaml"
if versioncmp($datadog_agent::_agent_major_version, '5') > 0 {
if $datadog_agent::_agent_major_version > 5 {
$dst_dir = "${datadog_agent::params::conf_dir}/postgres.d"
file { $legacy_dst:
ensure => 'absent',
Loading