Updating a connector in Azure

Learn how to update a connector through the Azure CLI

Periodically, you may need to update your Azure connector to help maintain functionality, performance, and security.

This article explains how to update and redeploy a connector through the Azure CLI.


Prerequisites


Update a connector

To update an Apono connector for Azure, follow these steps in the shell environment with Azure CLI installed:

  1. Set the APONO_CONNECTOR_ID environment variable to your chosen connector ID.

    export APONO_CONNECTOR_ID=apono-connector
  2. Set the APONO_TOKEN environment variable to your account token.

    export APONO_TOKEN=abcd1234-e5f6-7g8h-90123i45678
  3. Set the SUBSCRIPTION_ID environment variable to the Azure subscription ID.

    export SUBSCRIPTION_ID=abcdef01-23456789-0abc-def012345678
  4. Set the RESOURCE_GROUP_NAME environment variable to the Azure resource group name.

    export RESOURCE_GROUP_NAME=myResourceGroup0816
  5. Set the REGION environment variable.

    export REGION=$(az group show --name $RESOURCE_GROUP_NAME --query location --output tsv)
  6. Run the following command to deploy an updated version of the connector on the Azure Container Instance service.

```shell
az container create --subscription $SUBSCRIPTION_ID --resource-group $RESOURCE_GROUP_NAME --name $APONO_CONNECTOR_ID --ports 80 --os-type linux --image registry.apono.io/apono-connector:<<connectorVersion>> --environment-variables APONO_CONNECTOR_ID=$APONO_CONNECTOR_ID APONO_TOKEN=$APONO_TOKEN APONO_URL=api.apono.io CONNECTOR_METADATA='{"cloud_provider":"AZURE","subscription_id":"'"$SUBSCRIPTION_ID"'","resource_group":"'"$RESOURCE_GROUP_NAME"'","region":"'"$REGION"'","is_azure_admin":true}' --cpu 1 --memory 1.5 --registry-login-server registry.apono.io --registry-username apono --registry-password $APONO_TOKEN --location $REGION --assign-identity --query identity.principalId --output tsv
```

7. On the [**Connectors**](https://app.apono.io/connectors) page, verify that the connector has been updated.

Last updated