This guide will walk you through the process of creating a service principal in Azure that you can use with Komodo.

Prerequisites

  • Azure Account: Ensure you have an Azure account. If you haven’t already, you can sign up for free at Azure.
  • Azure Subscription: Have an Azure Subscription where you can perform the actions below. Create a subscription by following the instructions here.
  • Azure Cloud Shell Enabled (optional): This guide assumes you’ll be running commands in an Azure Cloud Shell. You can also run the setup from your local machine.
    • Instructions for enabling Azure Cloud Shell can be found here

If you need help with anything below, please let us know on Discord! 😊

Create a Service Principal

  1. Log in to the Azure Portal and start Cloud Shell from the top navigation of the Azure Portal
  1. Create a Service Principal by running the script below
export SUBSCRIPTION_ID=$(az account show | jq -r ".id")
az ad sp create-for-rbac --name komodo-sp \
  --role owner \
  --scopes /subscriptions/$SUBSCRIPTION_ID

If after running the above command you see a Failed to connect to MSI. Please make sure MSI is configured correctly. error, run az login and follow instructions to log in.

The above command will create a Service Principal and output credentials:

{
  "appId": "aaaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
  "displayName": "komodo-sp",
  "password": "aaaa~~bbbbbbbbbbbbbbbbbbbbbbbbb_ccccccc",
  "tenant": "aaaaaaaa-bbbb-cccc-dddd-eeeeffff"
}
  1. Copy the credentials and save them as a JSON file

Copy the output from Step 2 and save it as a JSON file locally.

Upload the Service Principal

  1. In the Komodo console, navigate to the Settings page

  2. Click Connect in the Azure section and upload the Service Principal credentials file.

And that’s it! You can now launch your workloads on Azure through Komodo! Follow this tutorial to get started.

FAQ