From 228820643488f77244ae127a00960eb9b1714a92 Mon Sep 17 00:00:00 2001 From: Steve Traylen Date: Sat, 22 Apr 2023 22:50:41 +0200 Subject: [PATCH] Correct timer_entry error message on a non-timer While ```puppet systemd::manage_dropin{'custom.conf': ensure => present, unit => 'my.service', timer_entry => { 'Calendar' => 'Daily' }, } ``` was failing the error message gave incorrect information. --- manifests/manage_dropin.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifests/manage_dropin.pp b/manifests/manage_dropin.pp index c901047c..6e6a578b 100644 --- a/manifests/manage_dropin.pp +++ b/manifests/manage_dropin.pp @@ -59,7 +59,7 @@ Optional[Systemd::Unit::Path] $path_entry = undef, ) { if $timer_entry and $unit !~ Pattern['^[^/]+\.timer'] { - fail("Systemd::Manage_unit[${name}]: timer_entry is only valid for timer units") + fail("Systemd::Manage_dropin[${name}]: for unit ${unit} timer_entry is only valid for timer units") } if $path_entry and $unit !~ Pattern['^[^/]+\.path'] {