Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 13 additions & 13 deletions azure.yaml
Original file line number Diff line number Diff line change
@@ -1,35 +1,35 @@
name: ai-foundry-agent
metadata:
template: [email protected]
location: eastus2

# Infra-only pattern - no services defined
# Container image deployment handled by hooks

infra:
path: ./infra
module: main

hooks:
# Phase 1: Create Entra app, generate config files
preprovision:
windows:
shell: pwsh
run: ./deployment/hooks/preprovision.ps1
continueOnError: false
posix:
shell: pwsh
run: ./deployment/hooks/preprovision.ps1
continueOnError: false

# Phase 2: Provision (automatic - Bicep templates with placeholder image)

# Phase 3: Build real image and deploy to Container App (runs after provision)
postprovision:
windows:
shell: pwsh
run: ./deployment/hooks/postprovision.ps1
continueOnError: false
posix:
shell: pwsh
run: ./deployment/hooks/postprovision.ps1
continueOnError: false

# Cleanup Entra app and config files
postdown:
windows:
shell: pwsh
run: ./deployment/hooks/postdown.ps1
continueOnError: false
posix:
shell: pwsh
run: ./deployment/hooks/postdown.ps1
continueOnError: false
5 changes: 4 additions & 1 deletion deployment/scripts/build-and-deploy-container.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,12 @@ if ($dockerAvailable) {

Push-Location $projectRoot
try {
$dockerfilePath = Join-Path "deployment" "docker" "frontend.Dockerfile"
docker build `
--platform linux/amd64 `
--build-arg ENTRA_SPA_CLIENT_ID=$ClientId `
--build-arg ENTRA_TENANT_ID=$TenantId `
-f .\deployment\docker\frontend.Dockerfile `
-f $dockerfilePath `
-t $imageName `
. 2>&1 | Out-Host

Expand Down Expand Up @@ -129,6 +131,7 @@ if ($dockerAvailable) {
$buildOutput = az acr build `
--registry $AcrName `
--image "ai-foundry-agent/web-dev:$imageTag" `
--platform linux/amd64 `
--build-arg ENTRA_SPA_CLIENT_ID=$ClientId `
--build-arg ENTRA_TENANT_ID=$TenantId `
--file .\deployment\docker\frontend.Dockerfile `
Expand Down
Loading