Skip to main content

Workload Configuration (Direct to Backend)

In environments where a cluster manager is not deployed, workloads can be configured to report directly to the Upwind backend. This approach uses the upwindctl CLI tool to instrument Azure Container Apps and App Service workloads.

Prerequisites

Before configuring workloads, you need the following:

ValueDescriptionHow to Get
Upwind Client IDOAuth client ID for backend authenticationUpwind Console → Settings → API Credentials
Upwind Client SecretOAuth client secret for backend authenticationUpwind Console → Settings → API Credentials
Azure Subscription IDThe Azure subscription containing your workloadsAzure Portal → Subscriptions

Install upwindctl

Install using the official install script:

curl -s https://get.upwind.io/upwindctl.sh | sh

Verify the installation:

upwindctl --help

Azure Container Apps

Instrument with upwindctl

The upwindctl azure instrument command adds the Upwind tracer to Azure Container Apps. It configures an init container to copy the tracer binary, prefixes the application command, and sets the required environment variables.

Single Container App

upwindctl azure instrument \
--subscription-id <SUBSCRIPTION_ID> \
--resource-group <RESOURCE_GROUP> \
--container-app <CONTAINER_APP_NAME> \
--client-id <UPWIND_CLIENT_ID> \
--client-secret <UPWIND_CLIENT_SECRET>

Batch Instrumentation (All Apps in an Environment)

To instrument all container apps within a Container App Environment:

upwindctl azure instrument \
--subscription-id <SUBSCRIPTION_ID> \
--resource-group <RESOURCE_GROUP> \
--container-app-env <CONTAINER_APP_ENVIRONMENT_NAME> \
--client-id <UPWIND_CLIENT_ID> \
--client-secret <UPWIND_CLIENT_SECRET>

This will instrument all container apps in the specified environment. The command will:

  • List all container apps in the environment
  • Instrument each app sequentially
  • Provide progress updates and a summary of successes/failures
  • Continue instrumenting remaining apps even if some fail
note

Instrumenting a Container App does not automatically apply to new containers added after the initial instrumentation. If you add new containers to an already-instrumented Container App, you must re-run the upwindctl azure instrument command to instrument them.

Flags

FlagDescriptionDefaultRequired
--subscription-idAzure subscription ID-Yes
--resource-groupAzure resource group name-Yes
--container-appContainer App name (single app mode)-One of --container-app or --container-app-env
--container-app-envContainer App Environment name (batch mode)-One of --container-app or --container-app-env
--client-idUpwind OAuth client ID-One of credential modes
--client-secretUpwind OAuth client secret-One of credential modes
--key-vault-nameAzure Key Vault name (alternative to direct credentials)-One of credential modes
--containerTarget container name. If not specified, all containers in the Container App will be instrumentedAll containersNo
--tracer-imageCustom tracer imagepublic.ecr.aws/upwindsecurity/images/tracer:0.7.16No
--api-securityEnable API security reportingfalseNo
--auth-endpointCustom OAuth token endpointhttps://oauth.upwind.io/oauth/tokenNo
--backend-api-hostCustom backend API hosthttps://agent.upwind.ioNo

Using Key Vault for Credentials

Instead of passing credentials directly, you can store them in an Azure Key Vault. The upwindctl tool will configure the Container App to read credentials from the vault at runtime using its managed identity.

upwindctl azure instrument \
--subscription-id <SUBSCRIPTION_ID> \
--resource-group <RESOURCE_GROUP> \
--container-app <CONTAINER_APP_NAME> \
--key-vault-name <KEY_VAULT_NAME>

Deinstrument

To remove the Upwind tracer from a Container App:

upwindctl azure deinstrument \
--subscription-id <SUBSCRIPTION_ID> \
--resource-group <RESOURCE_GROUP> \
--container-app <CONTAINER_APP_NAME>

Azure App Service

The upwindctl azure instrument-appservice command instruments Azure App Services with the Upwind tracer. The tracer binary is automatically extracted from the Docker image and uploaded to the App Service. The tool then sets the required environment variables and prefixes the startup command.

Instrument with upwindctl

Single App Service

upwindctl azure instrument-appservice \
--subscription-id <SUBSCRIPTION_ID> \
--resource-group <RESOURCE_GROUP> \
--app-name <APP_SERVICE_NAME> \
--client-id <UPWIND_CLIENT_ID> \
--client-secret <UPWIND_CLIENT_SECRET>

Batch Instrumentation (All Apps in a Service Plan)

To instrument all app services within an App Service Plan:

upwindctl azure instrument-appservice \
--subscription-id <SUBSCRIPTION_ID> \
--resource-group <RESOURCE_GROUP> \
--app-service-plan <APP_SERVICE_PLAN_NAME> \
--client-id <UPWIND_CLIENT_ID> \
--client-secret <UPWIND_CLIENT_SECRET>

This will instrument all app services in the specified plan. The command will:

  • List all app services in the plan
  • Extract the tracer binary once (shared across all apps for efficiency)
  • Instrument each app sequentially
  • Provide progress updates and a summary of successes/failures
  • Continue instrumenting remaining apps even if some fail

Flags

FlagDescriptionDefaultRequired
--subscription-idAzure subscription ID-Yes
--resource-groupAzure resource group name-Yes
--app-nameApp Service name (single app mode)-One of --app-name or --app-service-plan
--app-service-planApp Service Plan name (batch mode)-One of --app-name or --app-service-plan
--client-idUpwind OAuth client ID-One of credential modes
--client-secretUpwind OAuth client secret-One of credential modes
--key-vault-nameAzure Key Vault name (alternative to direct credentials)-One of credential modes
--tracer-imageTracer image to extract binary frompublic.ecr.aws/upwindsecurity/images/tracer:0.7.16No
--tracer-pathPath where tracer binary will be uploaded/home/upwind-tracerNo
--api-securityEnable API security reportingfalseNo
--process-report-intervalProcess report interval1mNo
--auth-endpointCustom OAuth token endpointhttps://oauth.upwind.io/oauth/tokenNo
--backend-api-hostCustom backend API hosthttps://agent.upwind.ioNo
--devUse Upwind dev environmentfalseNo

Using Key Vault for Credentials

upwindctl azure instrument-appservice \
--subscription-id <SUBSCRIPTION_ID> \
--resource-group <RESOURCE_GROUP> \
--app-name <APP_SERVICE_NAME> \
--key-vault-name <KEY_VAULT_NAME>

Deinstrument

To remove the Upwind tracer from an App Service:

upwindctl azure deinstrument-appservice \
--subscription-id <SUBSCRIPTION_ID> \
--resource-group <RESOURCE_GROUP> \
--app-name <APP_SERVICE_NAME>

Environment Variables

When using direct-to-backend mode, upwindctl configures the following environment variables:

VariableDescription
UPWIND_TRACER_REPORT_TO_BACKENDEnables direct backend reporting
UPWIND_TRACER_AUTH_ENDPOINTOAuth token endpoint
UPWIND_TRACER_BACKEND_API_HOSTUpwind backend API host
UPWIND_TRACER_REGISTRATION_HOSTUpwind registration host
UPWIND_TRACER_AUTH_CLIENT_IDOAuth client ID (when using direct credentials)
UPWIND_TRACER_AUTH_CLIENT_SECRETOAuth client secret (when using direct credentials)
UPWIND_KEY_VAULT_URLKey Vault URL (when using Key Vault mode)
UPWIND_CLOUD_PROVIDERSet to azure
UPWIND_CLOUD_ACCOUNT_IDAzure subscription ID
UPWIND_TRACER_EXTENDED_SYSCALLSExtended syscall tracing (when --api-security is set)
UPWIND_TRACER_REPORT_API_CATALOGAPI catalog reporting (when --api-security is set)

Batch Operations

Benefits of Batch Mode

  • Efficiency: Instrument multiple workloads with a single command
  • Consistency: Apply the same configuration across all workloads in an environment or plan
  • Time-saving: Especially useful for environments with many workloads
  • Resilience: Continues instrumenting even if some workloads fail

Batch Progress Reporting

During batch instrumentation, the tool provides:

  • Total number of workloads found
  • Progress indicators ([1/5], [2/5], etc.)
  • Success/failure status for each workload
  • Final summary with success and failure counts

Example Batch Output

Found 3 container app(s) to instrument:
- app-one
- app-two
- app-three

[1/3] Instrumenting container app 'app-one'...
SUCCESS: 'app-one' instrumented successfully

[2/3] Instrumenting container app 'app-two'...
ERROR: Failed to instrument 'app-two': container app not found

[3/3] Instrumenting container app 'app-three'...
SUCCESS: 'app-three' instrumented successfully

========================================
Batch instrumentation complete:
Total: 3
Success: 2
Failed: 1

Troubleshooting

Issue: Tracer fails to authenticate with backend

  • Verify the client ID and secret are correct
  • If using Key Vault, ensure the workload's managed identity has Get access to secrets in the vault
  • Check that the --auth-endpoint is reachable from the workload

Issue: upwindctl fails with permission errors

  • Ensure you are logged in with az login and have Contributor role on the resource group
  • For Key Vault mode, ensure you have permissions to create and manage Key Vault access policies

Issue: Batch instrumentation fails for some workloads

  • Review the error messages for each failed workload
  • Common causes include:
    • Workload is in a stopped or transitioning state
    • Insufficient permissions on specific workloads
    • Network connectivity issues
  • The command continues processing remaining workloads, so successful instrumentations are preserved
  • You can re-run the batch command - already instrumented workloads will be updated (idempotent operation)