jamesotron/cookbooks — Issue #5: not_if conditions not honored with bash
Author: mrampton
Created: 2011-11-09 21:11:01+00:00
State: open

Had to rewrite the [bash "install passenger/nginx"] block using the following instead -- passenger was repeatedly installed on subsequent runs otherwise.

bash "install passenger/nginx" do
unless Dir.exists? nginx_path or Dir.exists? "/usr/local/rvm"
user "root"
code <<-EOH
CC=#{cc} passenger-install-nginx-module --auto --auto-download --prefix="#{nginx_path}" --extra-configure-flags="#{node[:passenger][:production][:configure_flags]}"
EOH
end
end