Customizing azd Parameters

August 11, 2026 · View on GitHub

You can customize the deployment by setting azd environment variables before running azd up. These values are resolved into infra/main.parameters.json at provision time.

How to Set a Parameter

azd env set <PARAMETER_NAME> <value>

After setting parameters, run azd up (or azd provision) to apply them.

Available Parameters

Parameterazd Environment VariableDefaultDescription
environmentNameAZURE_ENV_NAME(prompted)Name of the environment; used to derive resource names (3-16 chars, alphanumeric).
locationAZURE_LOCATION(prompted)Primary Azure region for infrastructure resources.
contentUnderstandingLocationAZURE_CU_LOCATIONswedencentralRegion for the Azure AI Content Understanding resource.
azureAdTenantIdAZURE_AD_TENANT_ID(empty)Microsoft Entra tenant ID for App Service authentication.
azureAdClientIdAZURE_AD_CLIENT_ID(empty)App registration client ID for App Service authentication.
useExistingAiProjectUSE_EXISTING_AI_PROJECTfalseSet to true to reuse an existing Azure AI Foundry project.
existingAiFoundryServiceNameEXISTING_AI_FOUNDRY_SERVICE_NAME(empty)Name of an existing AI Foundry service to reuse.
existingAiFoundryProjectNameEXISTING_AI_FOUNDRY_PROJECT_NAME(empty)Name of an existing AI Foundry project to reuse.
existingAiFoundryEndpointEXISTING_AI_FOUNDRY_ENDPOINT(empty)Endpoint of an existing AI Foundry project to reuse.
existingAiSearchConnectionNameEXISTING_AI_SEARCH_CONNECTION_NAME(empty)Name of an existing Azure AI Search connection to reuse.
adminApiKeyADMIN_API_KEY(empty)Optional admin API key for privileged operations.
deploymentFlavorDEPLOYMENT_FLAVORbicepInfrastructure variant: bicep, avm, or avm-waf. See Deployment Flavor & Production (WAF) Parameters.
azureAiServiceLocationAZURE_ENV_AI_SERVICE_LOCATION(location)Region for the Azure AI (OpenAI) service.
appServicePlanSkuAZURE_ENV_APP_SERVICE_PLAN_SKUB3App Service Plan SKU for the backend and frontend web apps.
containerRegistryNameAZURE_ENV_CONTAINER_REGISTRY_NAME(generated)Name of an existing Azure Container Registry to reuse (leave empty to create one).
backendContainerImageTag / frontendContainerImageTagAZURE_ENV_IMAGE_TAGlatestContainer image tag to deploy.
deployCosmosAZURE_ENV_DEPLOY_COSMOSfalseDeploy Cosmos DB alongside SQL (SQL is the primary database; not required).
existingLogAnalyticsWorkspaceIdAZURE_ENV_EXISTING_LOG_ANALYTICS_WORKSPACE_RID(empty)Resource ID of an existing Log Analytics workspace to reuse.
existingFoundryProjectResourceIdAZURE_EXISTING_AIPROJECT_RESOURCE_ID(empty)Resource ID of an existing Azure AI Foundry project to reuse.
deployingUserPrincipalTypeDEPLOYING_USER_PRINCIPAL_TYPEUserPrincipal type of the deployer (User or ServicePrincipal); used for data-plane RBAC assignments.

Model Configuration

The AI model deployments are defined as parameters in infra/main.bicep with the following defaults for this solution. To change them, edit the defaults in main.bicep (they are not mapped as azd environment variables):

Bicep ParameterDefaultDescription
chatDeploymentNamegpt-5.2Azure OpenAI chat deployment (also used for insights generation). Deployed at 150k capacity on GlobalStandard.
embeddingDeploymentNametext-embedding-3-smallAzure OpenAI embedding deployment for hybrid search. Deployed at 80k capacity on GlobalStandard.
gptModelVersion2025-12-11Version of the chat model.
deployCosmosfalseSet to true to also deploy Cosmos DB (SQL is the primary database; not required).

Deployment Flavor & Production (WAF) Parameters

The infrastructure supports three deployment flavors, selected by the deploymentFlavor value in infra/main.parameters.json:

FlavorDescription
bicepDefault. Development / testing deployment without private networking.
avmAzure Verified Modules without private networking.
avm-wafWell-Architected Framework aligned: private networking, VNet, private endpoints, jumpbox VM + Bastion, and optional redundancy.

How to select a flavor: the deployment flavor is chosen by which parameters file is active — azd always reads infra/main.parameters.json. To deploy the Production (WAF) flavor, copy the WAF parameters file over the default:

Copy-Item ./infra/main.waf.parameters.json ./infra/main.parameters.json -Force
cp ./infra/main.waf.parameters.json ./infra/main.parameters.json

The WAF parameters file sets the following additional values. Flags without an azd environment variable are hard-coded in the file — edit the file directly to change them.

Parameterazd Environment VariableDefault (WAF file)Description
deploymentFlavorDEPLOYMENT_FLAVORavm-wafSelects the WAF infrastructure variant.
enableMonitoring(hard-coded)trueApplication Insights + Log Analytics.
enablePrivateNetworking(hard-coded)trueVNet, private endpoints, jumpbox VM, and Azure Bastion.
enableScalability(hard-coded)trueHigher SKUs and autoscale settings.
enableRedundancy(hard-coded)falseZone redundancy and Log Analytics workspace replication.
enableTelemetryAZURE_ENV_ENABLE_TELEMETRYtrueAnonymous deployment telemetry.
vmAdminUsernameAZURE_ENV_VM_ADMIN_USERNAME(empty)Jumpbox admin username (fallback; login is via Entra ID + Bastion).
vmAdminPasswordAZURE_ENV_VM_ADMIN_PASSWORD(empty)Jumpbox admin password.
vmSizeAZURE_ENV_VM_SIZEStandard_D2s_v5Jumpbox VM size.

Production prerequisite: the WAF jumpbox VM enables host encryption, so the EncryptionAtHost feature must be registered on the subscription before deploying. See Choose Deployment Type for the registration commands and VM credential setup.

Examples

Deploy to Australia East with a specific environment name:

azd env set AZURE_ENV_NAME kmdev
azd env set AZURE_LOCATION australiaeast
azd up

Reuse an existing Azure AI Foundry project:

azd env set USE_EXISTING_AI_PROJECT true
azd env set EXISTING_AI_FOUNDRY_SERVICE_NAME my-foundry-service
azd env set EXISTING_AI_FOUNDRY_PROJECT_NAME my-foundry-project
azd env set EXISTING_AI_FOUNDRY_ENDPOINT https://my-foundry.services.ai.azure.com/
azd up

Set the Content Understanding region:

azd env set AZURE_CU_LOCATION swedencentral
azd up

Deploy the Production (WAF) configuration with VM credentials:

Copy-Item ./infra/main.waf.parameters.json ./infra/main.parameters.json -Force
azd env set AZURE_ENV_VM_ADMIN_USERNAME azureadmin
azd env set AZURE_ENV_VM_ADMIN_PASSWORD <strong-password>
azd up

Viewing Current Values

azd env get-values

Next Steps

Return to the Deployment Guide to continue.