Skip to content

Instantly share code, notes, and snippets.

@marpada
Created June 16, 2015 00:52
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save marpada/d78adea6480b3ca5264c to your computer and use it in GitHub Desktop.
Save marpada/d78adea6480b3ca5264c to your computer and use it in GitHub Desktop.
php-rollback.rb
node[:deploy].each do |application, deploy|
if deploy[:application_type] != 'php'
Chef::Log.debug("Skipping deploy::php-rollback application #{application} as it is not a PHP app")
next
end
deploy deploy[:deploy_to] do
user deploy[:user]
action "rollback"
only_if do
File.exists?(deploy[:current_path])
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment