Skip to content

Instantly share code, notes, and snippets.

@jellybob
Forked from adamhjk/recipe.rb
Created July 1, 2010 09:28
Show Gist options
  • Save jellybob/459764 to your computer and use it in GitHub Desktop.
Save jellybob/459764 to your computer and use it in GitHub Desktop.
service "slapd" do
supports :restart => true, :status => true
action [ :enable, :start ]
end
# ... some shit ...
unless node[:slapd][:some_shit_has_been_done]
service "slapd" do
action :stop
end
# ... do more stuff, slapd will be stopped ...
service "slapd" do
action :start
end
node[:slapd][:some_shit_has_been_done] = true
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment