Hi there,
I was wondering if tasks can be written to be used within a different task's on block.
So as an example:
desc "Testing status"
task :status do
execute "sudo service nginx status"
end
desc "Testing get info "
task :start do
on roles(:web), in: :sequence do |server|
capture "hostname"
# how do I call testing:status here
end
end
So as per the code example above, I'd like to call the testing:status task on the same server loop defined in the testing:start task.
As far I know I cannot do an invoke within an on block in capistrano 3.
Versions:
- Ruby - 2.1.1
- Capistrano 3.1.0