I have a pretty robust bash script that bootstraps several aspects of my
app that I am trying call it from inside a Cap Task. I have been
using/developing the script for a while now and it requires input at
various points, but I can't figure out how to get Capistrano to display the
output or the prompts. If I run the script directly from terminal (I'm on
OS X) it, unsurprisingly works just fine. Here are what my tasks look like
at the moment:
desc "Runs the bootstrap shell script"
task :bootstrap, :roles => :app do
run "cd #{current_release}"
run "./config/bootstrap.sh"
end
desc "Runs the bootstrap shell script"
task :local_bootstrap, :roles => :app do
run_locally "./config/bootstrap.sh"
end
All I get is this:
$ cap ee:local_bootstrap
* 2013-02-05 19:45:13 executing `ee:local_bootstrap'
executing locally: "./config/bootstrap.sh"
It hangs right there because the script is waiting on input from the user.
I *really* don't want to rewrite all the logic in the script inside cap
tasks. Is there a way to feed the stream that the script outputs so that
users can see the output and respond to the prompts? I would really like be
able to make this work inside a Cap Task so that I can call the script from
other tasks and after deploys etc. but if I can't get this to work I guess
I'll just continue to run it manually.
Thanks
--
--
* You received this message because you are subscribed to the Google Groups
"Capistrano" group.
* To post to this group, send email to [email protected]
* To unsubscribe from this group, send email to
[email protected] For more options, visit this group at
http://groups.google.com/group/capistrano?hl=en
---
You received this message because you are subscribed to the Google Groups
"Capistrano" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.