When I used custom db:migrate task from capistrano/rails information about migrate processing isn't shown. To change that I customized db:migrate task and change log_level to :debug.
info '[deploy:migrate] Run `rake db:migrate`'
within release_path do
with rails_env: fetch(:rails_env) do
has_verbosity = defined?(SSHKit) && SSHKit.respond_to?(:config) && SSHKit.config.respond_to?(:output_verbosity)
if has_verbosity
verbosity_level = SSHKit.config.output_verbosity
SSHKit.config.output_verbosity = 0 # Logger::DEBUG
end
execute :rake, "db:migrate"
SSHKit.config.output_verbosity = verbosity_level if has_verbosity
end
end
All seems OK, but information about processing migration shows after that all migration are finished. But I want to show that information by steps (1. Migration 1 finished; 2. Info about that added to log; 3. Migration 2 finished; 4. Info about that added to log.). At now it works like: 1. Migration 1 finished; 2. Migration 2 finished; 4. Info about all migrations added to log.