dockersshdocker-composeazure-devopscontinuous-delivery

Azure DevOps: docker-compose over SSH normal messages interpreted as error


docker-compose, normal messages interpreted as errors in Azure DevOps

I have Release pipeline in Azure DevOps where I'm connecting to to server trough SSH and running docker-compose up command along with others.

Problem is that normal messages are interpreted as errors so release fails even when everything was successful.

errors in docker compose command even everything was successful

After this release everything is up and running.

Does anyone know why these messages were interpreted as errors?


Solution

  • I found out that docker writes those messages to stderr instead of stdout. In Azure DevOps pipeline in SSH task there is option Fail on STDERR which is checked by default. When I uncheck this option release no longer fails on this step even messages are marked as error.

    What really bothers me is that now even when some real error occurs, it will be ignored. I really don't know why they designed is like this, but that's for another topic.

    Links: https://github.com/docker/compose/issues/5296