Sunday, May 12, 2024

Azure Tools in Linux

In Linux/WSL2, configuring azure swa and cli tools for deployment of Single-Web-App.

Installing swa-cli and env-cmd commands:

$ sudo npm install -g @azure/static-web-apps-cli
$ sudo npm install -g env-cmd

$ swa login --no-use-keychain 
$ export SWA_CLI_DEPLOYMENT_TOKEN=xxxyyyzzz
$ swa deploy ./build --env production --no-use-keychain

 

Installing Azure CLI tools, source Install the Azure CLI on Linux:

$ curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash 

$ az login