This tool automates the steps to create Azure service principal for both unix and windows. More information on service principal can be found here.
Install Azure CLI. For Linux/Unix/Mac OS X, follow these instructions to install the Azure CLI.
npm install azure-sp-tool -g
-
azure login
- First login to your azure account -
azure account list
- Make sure your desired subscription is set to default -
azure-sp-tool create-sp
- Service principal is output to azure-credentials.json file