In the chef log, I've identified a task that takes a long time, and trying to figure out how to view it's output.
[2014-06-06T19:21:55+00:00] INFO: Processing execute[rake assets:precompile] action run (/srv/www/app/releases/20140606192141/deploy/before_migrate.rb line 11)
I've found the chef log file on the server and can see the normal chef output using the following:
tail -f /var/lib/aws/opsworks/chef/2014-06-06-19-21-20-01.log
It hangs on the previously mentioned log output until the precompile task is complete.
I know that the rake assets:precompile
tasks normally gives output, but how do I view it?
you need to run it with --trace when you are incorporating that in your deploy code. This is what I use, but take care to modify the user/group/cwd values to what you need
execute "rake assets:precompile" do
cwd release_path
user deploy_user
group deploy_group
command "bundle exec rake assets:precompile --trace "
environment deploy_resource.environment
end
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.