Skip to content

Commit 5c57896

Browse files
authored
replace systemd::service_limits with systemd::manage_dropin (#169)
1 parent 4071e5b commit 5c57896

File tree

4 files changed

+8
-7
lines changed

4 files changed

+8
-7
lines changed

.fixtures.yml

+1-3
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,4 @@ fixtures:
44
stdlib: 'https://github.com/puppetlabs/puppetlabs-stdlib.git'
55
svcprop: 'https://github.com/bolthole/puppet-svcprop.git'
66
selinux: 'https://github.com/voxpupuli/puppet-selinux.git'
7-
systemd:
8-
repo: 'https://github.com/camptocamp/puppet-systemd.git'
9-
ref: '2.12.0'
7+
systemd: 'https://github.com/camptocamp/puppet-systemd.git'

manifests/instance.pp

+5-2
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,11 @@
3838
}
3939

4040
if $limits {
41-
systemd::service_limits { $service_name:
42-
limits => $limits,
41+
systemd::manage_dropin { "${service_name}-90-limits.conf":
42+
unit => $service_name,
43+
filename => '90-limits.conf',
44+
notify_service => true,
45+
service_entry => $limits,
4346
}
4447
}
4548

metadata.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"dependencies": [
1515
{"name":"puppetlabs/stdlib","version_requirement":">= 4.13.1 < 10.0.0"},
1616
{"name":"puppetlabs/firewall","version_requirement":">= 0.1.0 < 9.0.0"},
17-
{"name":"puppet/systemd","version_requirement":">= 2.10.0 < 8.0.0"},
17+
{"name":"puppet/systemd","version_requirement":">= 6.0.0 < 8.0.0"},
1818
{"name":"puppet/selinux","version_requirement":">= 3.2.0 < 5.0.0"}
1919
],
2020
"operatingsystem_support": [

spec/defines/instance_spec.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
it { is_expected.to contain_class('memcached::instance::servicefile') }
4343
it { is_expected.to contain_service('[email protected]') }
4444
it { is_expected.to contain_systemd__unit_file('[email protected]') }
45-
it { is_expected.to contain_systemd__Service_limits('[email protected]') }
45+
it { is_expected.to contain_systemd__Manage_dropin('[email protected]-90-limits.conf') }
4646
end
4747

4848
context 'with overrides' do

0 commit comments

Comments
 (0)