feat: enable Azure Container Apps as optional execution method (#5646) #5650
+1,262
−4
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Fixes #5646
This PR implements Azure Container Apps as an optional execution method for the evals system, providing a serverless alternative to Docker execution. Users can now choose between Docker and Azure Container Apps by setting the
HOST_EXECUTION_METHOD
environment variable.Changes Made
Core Implementation
packages/evals/src/cli/azureContainerApps.ts
): Complete implementation with job management, monitoring, and cleanuppackages/evals/src/cli/runTask.ts
): Modified to support execution method selection viaHOST_EXECUTION_METHOD
packages/evals/src/cli/utils.ts
): Added utilities to detect Azure Container Apps vs Docker vs local executionDependencies & Configuration
@azure/arm-appcontainers@^2.1.0
and@azure/identity@^4.4.1
cli:azure
,azure:deploy
,azure:build-image
,azure:push-image
commands.env.azure
with Azure-specific configurationInfrastructure & Deployment
packages/evals/azure/main.bicep
): Complete Azure infrastructure deploymentpackages/evals/azure/deploy.sh
): Automated setup scriptTesting & Documentation
packages/evals/docs/azure-container-apps.md
): Setup guides, architecture overview, and troubleshootingKey Features
Execution Method Selection
Azure Container Apps Benefits
Infrastructure as Code
Testing
Verification of Acceptance Criteria
✅ Optional Azure Container Apps execution: Implemented via
HOST_EXECUTION_METHOD
environment variable✅ Backward compatibility: Existing Docker execution remains default and unchanged
✅ Configuration flexibility: Easy switching between execution methods
✅ Production readiness: Complete infrastructure deployment and monitoring
✅ Documentation: Comprehensive setup and usage guides
✅ Testing: Full test coverage for new functionality
Deployment Instructions
Set up Azure infrastructure:
cd packages/evals/azure ./deploy.sh
Configure environment:
cp .env.azure .env # Edit .env with your Azure resource details
Switch execution method:
Performance & Security
Breaking Changes
None. This is a purely additive feature that maintains full backward compatibility with existing Docker-based execution.
Checklist
Important
Adds Azure Container Apps as an optional execution method for evals, with infrastructure setup, configuration, testing, and documentation.
HOST_EXECUTION_METHOD
inrunTask.ts
.AzureContainerAppsExecutor
inazureContainerApps.ts
for job management.main.bicep
,main.bicepparam
) for Azure infrastructure deployment.deploy.sh
for automated Azure setup..env.azure
.package.json
with Azure-related scripts and dependencies.azureContainerApps.test.ts
andrunTask.test.ts
.azure-container-apps.md
.docker-compose.yml
to include Azure execution instructions.This description was created by
for 8e7d7ed. You can customize this summary. It will automatically update as commits are pushed.