diff --git a/azure.yaml b/azure.yaml index 09ec135..0add6da 100644 --- a/azure.yaml +++ b/azure.yaml @@ -11,7 +11,7 @@ infra: hooks: prepackage: posix: - sh: bash + shell: sh run: | # Validate environment name ENV_NAME=$(azd env get-values | grep AZURE_ENV_NAME | cut -d'=' -f2 | tr -d '"') @@ -116,7 +116,7 @@ hooks: postprovision: posix: - sh: bash + shell: sh run: | # Get environment values for the application azd env get-values > .env @@ -129,7 +129,7 @@ hooks: # azd hooks run postdeploy postdeploy: posix: - sh: bash + shell: sh run: | echo "Checking if vector store data needs to be loaded..." @@ -181,7 +181,21 @@ hooks: Write-Host "Data loading complete! Indexed $docCount documents." } - + + postdown: + posix: + shell: sh + run: | + echo "Cleaning up environment file..." + rm -f .env + echo "Environment file removed." + windows: + shell: pwsh + run: | + Write-Host "Cleaning up environment file..." + Remove-Item -Path .env -ErrorAction SilentlyContinue + Write-Host "Environment file removed." + services: api: project: ./packages-v1/server-api diff --git a/infra/main.bicep b/infra/main.bicep index 8a87cee..9488b9d 100644 --- a/infra/main.bicep +++ b/infra/main.bicep @@ -332,6 +332,7 @@ module acrPullRoleAssignment 'br/public:avm/ptn/authorization/resource-role-assi // Resources output AZURE_LOCATION string = location output AZURE_TENANT_ID string = tenant().tenantId +output AZURE_PRINCIPAL_ID string = managedIdentity.outputs.principalId output AZURE_RESOURCE_GROUP string = resourceGroup.name // OpenAI Resource @@ -367,6 +368,7 @@ output CONTAINER_APP_NAME string = containerApp.outputs.name output CONTAINER_APP_FQDN string = containerApp.outputs.fqdn output CONTAINER_APP_MANAGED_IDENTITY_CLIENT_ID string = managedIdentity.outputs.clientId output CONTAINER_APP_MANAGED_IDENTITY_PRINCIPAL_ID string = managedIdentity.outputs.principalId +output AZURE_CLIENT_ID string = managedIdentity.outputs.clientId // Service mapping for azd output SERVICE_API_NAME string = containerApp.outputs.name