|
|
|
@ -37,7 +37,7 @@ class PassengerWorker < Kernel::ModuleCoreWorker
|
|
|
|
|
begin
|
|
|
|
|
prepare_default_ruby_conf
|
|
|
|
|
log("install packages for passenger + nginx support: /usr/bin/puppet apply --detailed-exitcodes #{f_inst_pp}")
|
|
|
|
|
result_action = `/usr/bin/puppet apply --detailed-exitcodes "#{f_inst_pp}"`
|
|
|
|
|
result_action = `/usr/bin/puppet apply --detailed-exitcodes "#{f_inst_pp} 2>&1"`
|
|
|
|
|
ex_status = $?.exitstatus
|
|
|
|
|
if ex_status.to_i == 0 || ex_status.to_i == 2
|
|
|
|
|
log(result_action)
|
|
|
|
@ -45,7 +45,7 @@ class PassengerWorker < Kernel::ModuleCoreWorker
|
|
|
|
|
else
|
|
|
|
|
log(result_action)
|
|
|
|
|
log("Try to disable action: /usr/bin/puppet apply --detailed-exitcodes #{f_uninst_pp}")
|
|
|
|
|
result_action = `/usr/bin/puppet apply --detailed-exitcodes "#{f_uninst_pp}"`
|
|
|
|
|
result_action = `/usr/bin/puppet apply --detailed-exitcodes "#{f_uninst_pp} 2>&1"`
|
|
|
|
|
"module installation error. See log #{log_file}"
|
|
|
|
|
end
|
|
|
|
|
rescue => e
|
|
|
|
@ -64,7 +64,7 @@ class PassengerWorker < Kernel::ModuleCoreWorker
|
|
|
|
|
begin
|
|
|
|
|
log("uninstall packages for passenger + nginx support")
|
|
|
|
|
log("Try to disable action: /usr/bin/puppet apply --detailed-exitcodes #{f_uninst_pp}")
|
|
|
|
|
result_action = `/usr/bin/puppet apply --detailed-exitcodes "#{f_uninst_pp}"`
|
|
|
|
|
result_action = `/usr/bin/puppet apply --detailed-exitcodes "#{f_uninst_pp} 2>&1"`
|
|
|
|
|
ex_status = $?.exitstatus
|
|
|
|
|
if ex_status.to_i == 0 || ex_status.to_i == 2
|
|
|
|
|
log(result_action)
|
|
|
|
|