[chef] how to restart runit service if template changes


Chronological Thread 
  • From: David Montgomery < >
  • To:
  • Subject: [chef] how to restart runit service if template changes
  • Date: Fri, 8 Mar 2013 18:00:23 +0800



Hi,

I am using the runit cookbook.  Below is how I assume a restart of runit should look like but from the docs it apears that service is not supported for runit.  How do I accomplish the below?

 template "/home/ubuntu/druid/batch.json" do
    path "/home/ubuntu/druid/batch.json"
    source "batch.json.erb"
    owner "root"
    group "root"
    mode "0644"
    variables({
      :s3bucket => "#{s3bucket}",:mysql_host => "#{mysql_host}", :mysql_username => "#{mysql_username}", :mysql_password => "#{mysql_password}"
    })
    notifies :restart, resources(:service => "Batch")
  end
 
  service "Batch" do
    supports :restart => true, :start => true, :stop => true
    action :enable
  end
 
  runit_service "Batch"



Archive powered by MHonArc 2.6.16.

§