Skip to content

Commit e765807

Browse files
jaymzhfacebook-github-bot
authored andcommitted
fb_spamassassin: Fix timer jobs (facebook#306)
Summary: Somehow I had gotten it in my head when I wrote a bunch of these cookbooks that timer jobs needed to `:enable`'d but `:start` would run the actual job. That is, of course, not true, the underlying _service_ can be started to do an immediate run. As a result the update jobs never ran, when expected. This fixes that. Signed-off-by: Phil Dibowitz <phil@ipom.com> Pull Request resolved: facebook#306 Differential Revision: D73198736 fbshipit-source-id: 6a50a4b2aa87eb8bc1382ed8f3728d4129b8cef6
1 parent e93172e commit e765807

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cookbooks/fb_spamassassin/recipes/default.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -123,13 +123,13 @@
123123
systemd_unit 'enable spam assassin update job' do
124124
only_if { node['fb_spamassassin']['enable_update_job'] }
125125
unit_name "#{update_job}.timer"
126-
action [:enable]
126+
action [:enable, :start]
127127
end
128128

129129
systemd_unit 'disable spam assassin update job' do
130130
not_if { node['fb_spamassassin']['enable_update_job'] }
131131
unit_name "#{update_job}.timer"
132-
action [:disable]
132+
action [:stop, :disable]
133133
end
134134

135135
service 'spamd' do

0 commit comments

Comments
 (0)