Skip to content

Commit

Permalink
Add comment in manage_unit deployed files
Browse files Browse the repository at this point in the history
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`.
  • Loading branch information
traylenator committed Apr 22, 2023
1 parent 76f42b7 commit c9582bd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions spec/defines/manage_dropin_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
}
end

it { is_expected.to compile.with_all_deps }
it { is_expected.to contain_systemd__dropin_file('foobar.conf').with_content(%r{^# Deployed with puppet$}) }

context 'setting some parameters simply' do
let(:params) do
super().merge(
Expand Down
1 change: 1 addition & 0 deletions templates/unit_file.epp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
Optional[Hash] $install_entry,
Optional[Hash] $timer_entry,
| -%>
# Deployed with puppet
<% if $unit_entry { -%>

[Unit]
Expand Down

0 comments on commit c9582bd

Please sign in to comment.