Show output of pg_dump / pg_restore commands in case of failures

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

The rake task gitlab:db:decomposition:migrate is using pg_dump and pg_resture. If something goes wrong with those command (for exmaple, the ci database is not found), they fail silently and we show a 'migration finished' message

If one of those command fails, we should:

  • print the output of the command
  • exit the rake task with exit code 1
  • Print something like 'Migration failed'
Edited by 🤖 GitLab Bot 🤖