Search code examples
azure-devopsazure-pipelineschocolatey

Chocolatey startup takes unpredictable time on Azure Pipelines (sometimes minutes)


We use Chocolately in our Azure Pipelines setup. Chocolatey startup seems to take an unpredictable amount of time: it could be as short as seconds or as long as minutes.

In this example it took 13 seconds, while in this one it took 2 minutes 20 seconds. It always gets stuck after the output line "Chocolatey v0.10.15", i.e. it seems that it is not package installation that takes long, but Chocolatey startup.

Questions:

  • Is this expected with Azure Pipelines?
  • Is there anything I can do about it, and make Chocolatey startup reasonably fast?

Solution

  • After checking your logs, we find the faster one used the agent 'WIN-EHTFAB4ECBV', but the another one used the agent 'fv-az238-568'. Since they use different self-agent, your issue may be caused by machine performance. You can try to use the demands to help you select the specified agent to run this pipeline.