Skip to content
Merged
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
4 changes: 2 additions & 2 deletions azure.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ hooks:
Write-Host "Web app URL: "
Write-Host "$env:WEB_APP_URL" -ForegroundColor Cyan
Write-Host "`nRun the following command in your Bash terminal. It will grant the necessary permissions between resources and your user account, and also process and load the sample data into the application."
Write-Host "bash ./infra/scripts/process_sample_data.sh $env:AZURE_RESOURCE_GROUP" -ForegroundColor Cyan
Write-Host "bash ./infra/scripts/process_sample_data.sh" -ForegroundColor Cyan
shell: pwsh
continueOnError: false
interactive: true
Expand All @@ -26,7 +26,7 @@ hooks:
echo $WEB_APP_URL
echo ""
echo "Run the following command in your Bash terminal. It will grant the necessary permissions between resources and your user account, and also process and load the sample data into the application."
echo "bash ./infra/scripts/process_sample_data.sh $env:AZURE_RESOURCE_GROUP"
echo "bash ./infra/scripts/process_sample_data.sh"
shell: sh
continueOnError: false
interactive: true
59 changes: 40 additions & 19 deletions docs/AVMPostDeploymentGuide.md
Original file line number Diff line number Diff line change
@@ -1,30 +1,51 @@
# AVM Post Deployment Guide

> **📋 Note**: This guide is specifically for post-deployment steps after using the AVM template. For complete deployment from scratch, see the main [Deployment Guide](./DeploymentGuide.md).

---

This document provides guidance on post-deployment steps after deploying the Build Your Own Copilot Accelerator from the [AVM (Azure Verified Modules) repository](https://github.com/Azure/bicep-registry-modules/tree/main/avm/ptn/sa/build-your-own-copilot).

## Post Deployment Steps
1. Clone the Repository
First, clone this repository to access the post-deployment scripts:
```bash
git clone https://github.com/microsoft/Build-your-own-copilot-Solution-Accelerator.git
```
```bash
cd Build-your-own-copilot-Solution-Accelerator
```

2. Import Sample Data -Run bash command printed in the terminal. The bash command will look like the following:
### 1. Clone the Repository
First, clone this repository to access the post-deployment scripts:

```bash
git clone https://github.com/microsoft/Build-your-own-copilot-Solution-Accelerator.git
cd Build-your-own-copilot-Solution-Accelerator
```

### 2. Import Sample Data

**Choose the appropriate command based on your deployment method:**

**If you deployed using custom templates, ARM/Bicep deployments, or `az deployment group` commands:**
```bash
bash ./infra/scripts/process_sample_data.sh <your-resource-group-name>
```
> **Note**: Replace `<your-resource-group-name>` with the actual name of the resource group containing your deployed Azure resources.

> **💡 Tip**: If the deployment metadata does not exist in Azure or has been deleted, the script will prompt you to manually enter the required configuration values.

**If you deployed using `azd up` command:**
```bash
bash ./infra/scripts/process_sample_data.sh
```
> **Note**: The script will automatically take required values from your `azd` environment.

> **💡 Tip**: Since this guide is for AVM deployments, you'll most likely use the first command with your resource group name.

### 3. Configure Authentication

```bash
bash ./infra/scripts/process_sample_data.sh <resourceGroupName>
```
If the deployment does not exist or has been deleted – The script will prompt you to manually enter the required values
Follow the steps in [App Authentication](./AppAuthentication.md) to configure authentication in App Service.

3. Add Authentication Provider
> **Note**: Authentication changes can take up to 10 minutes to propagate.

Follow steps in [App Authentication](https://github.com/microsoft/Build-your-own-copilot-Solution-Accelerator/blob/main/docs/AppAuthentication.md) to configure authentication in app service.
>Note that Authentication changes can take up to 10 minutes.
### 4. Troubleshooting: Cleaning Up After a Failed Deployment

4. Deleting Resources After a Failed Deployment
If your deployment fails and you need to clean up resources, follow the steps in [Delete Resource Group](./DeleteResourceGroup.md).

Follow steps in [Delete Resource Group](https://github.com/microsoft/Build-your-own-copilot-Solution-Accelerator/blob/main/docs/DeleteResourceGroup.md) if your deployment fails and/or you need to clean up the resources.
---

By following these steps, youll ensure a smooth transition from deployment to hands-on usage.
By following these steps, you'll ensure a smooth transition from deployment to hands-on usage.
62 changes: 28 additions & 34 deletions docs/DeploymentGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ You can run this solution using [GitHub Codespaces](https://docs.github.com/en/c
</details>

<details>
<summary><b>Deploy in VS Code</b></summary>
<summary><b>Deploy in VS Code Dev Containers</b></summary>

### VS Code Dev Containers

Expand Down Expand Up @@ -136,26 +136,7 @@ Consider the following settings during your deployment to modify specific settin
<details>
<summary><b>Configurable Deployment Settings</b></summary>

When you start the deployment, most parameters will have **default values**, but you can update the below settings by following the steps [here](CustomizingAzdParameters.md):


| **Setting** | **Description** | **Default value** |
| ------------------------------------ | -------------------------------------------------------------------------------------------------- | ------------------------ |
| **Environment Name** | A **3-20 character alphanumeric value** used to generate a unique ID to prefix the resources. | `azdtemp` |
| **Cosmos Location** | A **less busy** region for **CosmosDB**, useful in case of availability constraints. | `eastus2` |
| **Deployment Type** | Select from a drop-down list (`Standard`, `GlobalStandard`). | `GlobalStandard` |
| **GPT Model** | Azure OpenAI GPT model to deploy. | `gpt-4o-mini` |
| **GPT Model Deployment Capacity** | Configure capacity for **GPT models**. Choose based on Azure OpenAI quota. | `30` |
| **Embedding Model** | OpenAI embedding model used for vector similarity. | `text-embedding-ada-002` |
| **Embedding Model Capacity** | Set the capacity for **embedding models**. Choose based on usage and quota. | `80` |
| **Image Tag** | The version of the Docker image to use (e.g., `latest_waf`, `dev`, `hotfix`). | `latest_waf` |
| **Azure OpenAI API Version** | Set the API version for OpenAI model deployments. | `2025-04-01-preview` |
| **AZURE_LOCATION** | Sets the Azure region for resource deployment. | `<User selects during deployment>` |
| **Existing Log Analytics Workspace** | To reuse an existing Log Analytics Workspace ID instead of creating a new one. | *(empty)* |
| **Existing AI Foundry Project Resource ID** | To reuse an existing AI Foundry Project Resource ID instead of creating a new one. | *(empty)* |



When you start the deployment, most parameters will have **default values**, but you can update the below settings by following the steps [here](CustomizingAzdParameters.md)

</details>

Expand Down Expand Up @@ -257,22 +238,35 @@ This will rebuild the source code, package it into a container, and push it to t

## Post Deployment Steps

1. **Import Sample Data**
-Run bash command printed in the terminal. The bash command will look like the following:
```shell
bash ./infra/scripts/process_sample_data.sh
```
if you don't have azd env then you need to pass parameters along with the command. Then the command will look like the following:
```shell
bash ./infra/scripts/process_sample_data.sh <resourceGroupName> <cosmosDbAccountName> <storageAccount> <storageContainerName> <keyvaultName> <sqlServerName> <sqlDatabaseName> <webAppUserManagedIdentityClientId> <webAppUserManagedIdentityDisplayName> <aiFoundryResourceName> <aiSearchResourceName>
```
### 1. Import Sample Data

**Choose the appropriate command based on your deployment method:**

**If you deployed using `azd up` command:**
```bash
bash ./infra/scripts/process_sample_data.sh
```
> **Note**: The script will automatically take required values from your `azd` environment.

**If you deployed using custom templates, ARM/Bicep deployments, or `az deployment group` commands:**
```bash
bash ./infra/scripts/process_sample_data.sh <your-resource-group-name>
```
> **Note**: Replace `<your-resource-group-name>` with the actual name of the resource group containing your deployed Azure resources.

> **💡 Tip**: If the deployment metadata does not exist in Azure or has been deleted, the script will prompt you to manually enter the required configuration values.

> **💡 Tip**: Since this guide is for azd deployment, you'll most likely use the first command without resource group name.

### 2. Configure Authentication

Follow the steps in [App Authentication](./AppAuthentication.md) to configure authentication in App Service.

2. **Add Authentication Provider**
- Follow steps in [App Authentication](./AppAuthentication.md) to configure authentication in app service. Note that Authentication changes can take up to 10 minutes.
> **Note**: Authentication changes can take up to 10 minutes to propagate.

3. **Deleting Resources After a Failed Deployment**
### 3. Troubleshooting: Cleaning Up After a Failed Deployment

- Follow steps in [Delete Resource Group](DeleteResourceGroup.md) if your deployment fails and/or you need to clean up the resources.
If your deployment fails and you need to clean up resources, follow the steps in [Delete Resource Group](./DeleteResourceGroup.md).

## Environment configuration for local development & debugging
> Set APP_ENV in your .env file to control Azure authentication. Set the environment variable to dev to use Azure CLI credentials, or to prod to use Managed Identity for production. **Ensure you're logged in via az login when using dev in local**.
Expand Down
Loading