From f2318e92da0abfefd3883cd528896e9c86d507e7 Mon Sep 17 00:00:00 2001 From: Harsh-Microsoft Date: Wed, 1 Oct 2025 14:01:02 +0530 Subject: [PATCH 1/2] Add AVM Post Deployment Guide --- docs/AVMPostDeploymentGuide.md | 164 +++++++++++++++++++++++++++++++++ 1 file changed, 164 insertions(+) create mode 100644 docs/AVMPostDeploymentGuide.md diff --git a/docs/AVMPostDeploymentGuide.md b/docs/AVMPostDeploymentGuide.md new file mode 100644 index 00000000..82e48446 --- /dev/null +++ b/docs/AVMPostDeploymentGuide.md @@ -0,0 +1,164 @@ +# AVM Post Deployment Guide + +This document provides guidance on post-deployment steps after deploying the Content processing solution accelerator from the [AVM (Azure Verified Modules) repository](https://github.com/Azure/bicep-registry-modules/tree/main/avm/ptn/sa/content-processing). + +## Overview + +After successfully deploying the Content Processing Solution Accelerator using the AVM template, you'll need to complete some configuration steps to make the solution fully operational. This guide walks you through: + +- Setting up schema definitions for document processing +- Importing sample data to test the solution +- Configuring authentication for secure access +- Verifying your deployment is working correctly + +## Prerequisites + +Before starting the post-deployment process, ensure you have the following: + +### Required Software + +1. **[PowerShell](https://learn.microsoft.com/en-us/powershell/scripting/install/installing-powershell?view=powershell-7.4)** (v7.0+ recommended) - Available for Windows, macOS, and Linux + +2. **[Azure CLI](https://learn.microsoft.com/en-us/cli/azure/install-azure-cli)** (v2.50+) - Command-line tool for managing Azure resources + +3. **[Git](https://git-scm.com/downloads/)** - Version control system for cloning the repository + +4. **Deployed Infrastructure** - A successful Content processing solution accelerator deployment from the [AVM repository](https://github.com/Azure/bicep-registry-modules/tree/main/avm/ptn/sa/content-processing) + +#### Important Note for PowerShell Users + +If you encounter issues running PowerShell scripts due to execution policy restrictions, you can temporarily adjust the `ExecutionPolicy` by running the following command in an elevated PowerShell session: + +```powershell +Set-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass +``` + +This will allow the scripts to run for the current session without permanently changing your system's policy. + +## Post-Deployment Steps + +### Step 1: Clone the Repository + +First, clone this repository to access the post-deployment scripts: + +```powershell +git clone https://github.com/microsoft/content-processing-solution-accelerator.git +cd content-processing-solution-accelerator +``` + +### Step 2: Verify Your Deployment + +Before proceeding, verify that your AVM deployment completed successfully: + +1. **Check Resource Group**: Confirm all expected resources are present in your Azure resource group +2. **Verify Container Apps**: Ensure both API and Web container apps are running +3. **Test Connectivity**: Verify you can access the container app URLs + +### Step 3: Optional - Rebuild and Push Container Images + +If you need to rebuild the source code and push updated containers to the deployed Azure Container Registry: + +**Linux/macOS**: +```bash +cd ./infra/scripts/ +./docker-build.sh +``` + +**Windows (PowerShell)**: +```powershell +cd .\infra\scripts\ +.\docker-build.ps1 +``` + +> **Note**: This step is only necessary if you've modified the source code or need to update the container images. + +### Step 4: Register Schema Files + +Configure the solution with sample schemas for document processing: + +> 💡 **Want to customize schemas?** [Learn more about adding your own schemas here](./CustomizeSchemaData.md) + +#### 4.1 Get API Service Endpoint + +1. Navigate to your Azure portal and find your resource group +2. Locate the API container app (named **ca-**_\_**-api**) +3. Copy the Application URL from the Overview page + + ![Check API Service Url](./images/CheckAPIService.png) + +#### 4.2 Register Sample Schemas + +Navigate to the schemas directory and run the registration script: + +```powershell +cd src/ContentProcessorAPI/samples/schemas +``` + +**Linux/macOS**: +```bash +./register_schema.sh https:///schemavault/ schema_info_sh.json +``` + +**Windows**: +```powershell +./register_schema.ps1 https:///schemavault/ .\schema_info_ps1.json +``` + +#### 4.3 Verify Schema Registration + +Check that schemas were registered successfully: +![Schema file registration](./images/SchemaFileRegistration.png) + +### Step 5: Import Sample Data + +Upload sample documents to test the solution: + +#### 5.1 Get Schema IDs + +Note down the Schema IDs for "Invoice" and "Property Loss Damage Claim Form" from the previous step. + +#### 5.2 Upload Sample Documents + +Navigate to the samples directory: + +```powershell +cd src/ContentProcessorAPI/samples/ +``` + +**Upload Invoice samples (Linux/macOS)**: +```bash +./upload_files.sh https:///contentprocessor/submit ./invoices +``` + +**Upload Property Claims samples (Linux/macOS)**: +```bash +./upload_files.sh https:///contentprocessor/submit ./propertyclaims +``` + +**Upload Invoice samples (Windows)**: +```powershell +./upload_files.ps1 https:///contentprocessor/submit .\invoices +``` + +**Upload Property Claims samples (Windows)**: +```powershell +./upload_files.ps1 https:///contentprocessor/submit .\propertyclaims +``` + +### Step 6: Configure Authentication + +Set up secure access to your application: + +1. Follow the detailed steps in [Configure App Authentication](./ConfigureAppAuthentication.md) +2. **Important**: Authentication changes can take up to 10 minutes to take effect + +## Next Steps + +Now that you've completed your deployment, you can start using the solution. Try out these things to start getting familiar with the capabilities: +* Open the web container app URL in your browser and explore the web user interface and upload your own invoices. +* [Create your own schema definition](./CustomizeSchemaData.md), so you can upload and process your own types of documents. +* [Ingest the API](API.md) for processing documents programmatically. + +--- + +> **📋 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). \ No newline at end of file From d3600b2d49a6553e09d2d0f2a5a7a51592295435 Mon Sep 17 00:00:00 2001 From: Harsh-Microsoft Date: Wed, 1 Oct 2025 17:28:01 +0530 Subject: [PATCH 2/2] Refine AVM Post Deployment Guide by streamlining post-deployment steps and enhancing clarity --- docs/AVMPostDeploymentGuide.md | 129 +++------------------------------ 1 file changed, 12 insertions(+), 117 deletions(-) diff --git a/docs/AVMPostDeploymentGuide.md b/docs/AVMPostDeploymentGuide.md index 82e48446..aae07b64 100644 --- a/docs/AVMPostDeploymentGuide.md +++ b/docs/AVMPostDeploymentGuide.md @@ -1,15 +1,14 @@ # 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 Content processing solution accelerator from the [AVM (Azure Verified Modules) repository](https://github.com/Azure/bicep-registry-modules/tree/main/avm/ptn/sa/content-processing). ## Overview -After successfully deploying the Content Processing Solution Accelerator using the AVM template, you'll need to complete some configuration steps to make the solution fully operational. This guide walks you through: - -- Setting up schema definitions for document processing -- Importing sample data to test the solution -- Configuring authentication for secure access -- Verifying your deployment is working correctly +After successfully deploying the Content Processing Solution Accelerator using the AVM template, you'll need to complete some configuration steps to make the solution fully operational. ## Prerequisites @@ -46,119 +45,15 @@ git clone https://github.com/microsoft/content-processing-solution-accelerator.g cd content-processing-solution-accelerator ``` -### Step 2: Verify Your Deployment - -Before proceeding, verify that your AVM deployment completed successfully: - -1. **Check Resource Group**: Confirm all expected resources are present in your Azure resource group -2. **Verify Container Apps**: Ensure both API and Web container apps are running -3. **Test Connectivity**: Verify you can access the container app URLs - -### Step 3: Optional - Rebuild and Push Container Images - -If you need to rebuild the source code and push updated containers to the deployed Azure Container Registry: - -**Linux/macOS**: -```bash -cd ./infra/scripts/ -./docker-build.sh -``` - -**Windows (PowerShell)**: -```powershell -cd .\infra\scripts\ -.\docker-build.ps1 -``` - -> **Note**: This step is only necessary if you've modified the source code or need to update the container images. - -### Step 4: Register Schema Files - -Configure the solution with sample schemas for document processing: - -> 💡 **Want to customize schemas?** [Learn more about adding your own schemas here](./CustomizeSchemaData.md) - -#### 4.1 Get API Service Endpoint - -1. Navigate to your Azure portal and find your resource group -2. Locate the API container app (named **ca-**_\_**-api**) -3. Copy the Application URL from the Overview page - - ![Check API Service Url](./images/CheckAPIService.png) - -#### 4.2 Register Sample Schemas - -Navigate to the schemas directory and run the registration script: - -```powershell -cd src/ContentProcessorAPI/samples/schemas -``` - -**Linux/macOS**: -```bash -./register_schema.sh https:///schemavault/ schema_info_sh.json -``` - -**Windows**: -```powershell -./register_schema.ps1 https:///schemavault/ .\schema_info_ps1.json -``` - -#### 4.3 Verify Schema Registration - -Check that schemas were registered successfully: -![Schema file registration](./images/SchemaFileRegistration.png) - -### Step 5: Import Sample Data - -Upload sample documents to test the solution: - -#### 5.1 Get Schema IDs +### Step 2: Complete Post-Deployment Configuration -Note down the Schema IDs for "Invoice" and "Property Loss Damage Claim Form" from the previous step. +Follow the **[Post Deployment Steps](./DeploymentGuide.md#post-deployment-steps)** section in the main Deployment Guide, which includes: -#### 5.2 Upload Sample Documents - -Navigate to the samples directory: - -```powershell -cd src/ContentProcessorAPI/samples/ -``` - -**Upload Invoice samples (Linux/macOS)**: -```bash -./upload_files.sh https:///contentprocessor/submit ./invoices -``` - -**Upload Property Claims samples (Linux/macOS)**: -```bash -./upload_files.sh https:///contentprocessor/submit ./propertyclaims -``` - -**Upload Invoice samples (Windows)**: -```powershell -./upload_files.ps1 https:///contentprocessor/submit .\invoices -``` - -**Upload Property Claims samples (Windows)**: -```powershell -./upload_files.ps1 https:///contentprocessor/submit .\propertyclaims -``` - -### Step 6: Configure Authentication - -Set up secure access to your application: - -1. Follow the detailed steps in [Configure App Authentication](./ConfigureAppAuthentication.md) -2. **Important**: Authentication changes can take up to 10 minutes to take effect +1. **[Optional: Publishing Local Build Container to Azure Container Registry](./DeploymentGuide.md#post-deployment-steps)** +2. **[Register Schema Files](./DeploymentGuide.md#post-deployment-steps)** +3. **[Import Sample Data](./DeploymentGuide.md#post-deployment-steps)** +4. **[Add Authentication Provider](./DeploymentGuide.md#post-deployment-steps)** ## Next Steps -Now that you've completed your deployment, you can start using the solution. Try out these things to start getting familiar with the capabilities: -* Open the web container app URL in your browser and explore the web user interface and upload your own invoices. -* [Create your own schema definition](./CustomizeSchemaData.md), so you can upload and process your own types of documents. -* [Ingest the API](API.md) for processing documents programmatically. - ---- - -> **📋 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). \ No newline at end of file +Once configuration is complete, see the **[Next Steps](./DeploymentGuide.md#next-steps)** section in the main Deployment Guide to start using the solution.