Another reason for the generic Invoke-RestMethod "http://localhost:8079/api/http/routers PS error

Error:

ERROR: for traefik  Container "67a617e90af1" is unhealthy.

ERROR: Encountered errors while bringing up the project.

Waiting for CM to become available...

Invoke-RestMethod : Unable to connect to the remote server

At C:\MVP-Site\up.ps1:35 char:19

+ ...   $status = Invoke-RestMethod "http://localhost:8079/api/http/routers ...

+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-RestMethod], WebExc

   eption

    + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand


Docker logs result:


IIS Stopped already

Computer free space:


The context was, up.ps1 had all containers healthy except traefik. As a result, the site wouldn't start. Then, I realized I recently added some logic in a new patch for preProcessRequest pipeline, when I commented the same and did up.ps1, traefik was fine! So, you could have a wrong pipeline processor (logic) and that could be the cause for traefik not being able to start hence the generic error!


Comments