Skip to content

Commit f857e5b

Browse files
committed
Add comment in manage_unit deployed files
It's useful to see clearly see that files deployed with puppet are deployed with puppet. Add a comment to top of files deployed by `systemd::manage_unit` and `systemd::manage_dropin`.
1 parent 67c1ae4 commit f857e5b

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

spec/defines/manage_dropin_spec.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
}
1818
end
1919

20+
it { is_expected.to compile.with_all_deps }
21+
it { is_expected.to contain_systemd__dropin_file('foobar.conf').with_content(%r{^# Deployed with puppet$}) }
22+
2023
context 'setting some parameters simply' do
2124
let(:params) do
2225
super().merge(

templates/unit_file.epp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@
1919
]
2020

2121
-%>
22+
# Deployed with puppet
23+
#
2224
<%-
2325
$_unit_sections.each | $_section | {
2426
$_values = getvar("${downcase($_section)}_entry")

0 commit comments

Comments
 (0)