azd passes environment variables to framework build subprocesses
Introduced 2026-02-28 · score 0.93
HOW TO USE IT
For a non-Docker Node.js, .NET, Java, Python, or SWA service build that needs `azd` environment variables, set the values in `.azure/<env>/.env`; `azd` passes them to framework build subprocesses. Run the applicable `azd` build or deployment workflow for the service.
azd env set <KEY> <VALUE> --environment <env>azd upWHY THIS HELPS
Build a Node.js, .NET, Java, Python, or SWA service that needs azd environment variables during its build.
BEFORE THIS CHANGE
Previously only Docker builds and hooks received these variables.
REQUIREMENTS AND LIMITATIONS
- Version: 1.23.7
- <KEY> (required): Environment variable name to set.
- <VALUE> (required): Value to store for the variable.
- --environment <env>: Selects the named environment whose `.env` file is updated.
- Applies to non-Docker framework service build subprocesses.
- The change depends on #6894 (pnpm/yarn support).
FIRST-PARTY EVIDENCE
- https://github.com/Azure/azure-dev/releases/tag/azure-dev-cli_1.23.7
- https://github.com/Azure/azure-dev/pull/6905
- https://learn.microsoft.com/en-us/azure/developer/azure-developer-cli/manage-environment-variables
Check the installed version and the source before using it. Entry JSON