Azure SWA CLI - Localhost Cannot be Resolved

222 Views Asked by At

Ever since I upgraded @azure/static-web-apps-cli, things doesn't work as exepcted.

Thus, I'm re-reading the following doucmentation: https://azure.github.io/static-web-apps-cli/docs/cli/swa-start/

When I run command below, I get an error.

swa start http://localhost:3000 --api-devserver-url http://localhost:7071

"localhost" can not be resolved to either IPv4 or IPv6. Please check your network settings.

node "\npm\node_modules@azure\static-web-apps-cli\dist\msha\server.js" exited with code 0

Other notes:

  • Current version: Azure Static Web Apps CLI (1.1.4)
  • And yes, port 3000 and port 7071 is running fine.

Any clues?

1

There are 1 best solutions below

0
On

Not sure what was updated in the latest package, but something doesn't quite seem right in the latest.

To fix the issue above, I simply had to downgrade.

Current working version: Azure Static Web Apps CLI (1.0.2)