Skip to content

Latest commit

 

History

History
53 lines (32 loc) · 3.59 KB

README.md

File metadata and controls

53 lines (32 loc) · 3.59 KB

Managed App Instructions

This guide is a temporary document that walks through the process to convert the graphrag solution accelerator to a managed app.

Prerequisites

1. create a ACR and push the code to a docker image.

2. This managed app uses storage account to deploy, so please copy the storage account name and the SAS key.

3. When publishing the managed app , please turn on anon access to the Blob where the package can be accessed.

Steps to build Managed App

1. Auto format the bicep code

As a precaution, start by auto-formating and linting the bicep code to detect any mistakes early-on.

cd <repo_root_directory>/infra
find . -type f -name "*.bicep" -exec az bicep format --file {} \;
find . -type f -name "*.bicep" -exec az bicep lint --file {} \;

2. Convert bicep -> ARM

az bicep build --file main.bicep --outfile managed-app/mainTemplate.json

3. Create & test the Azure portal interface

Use the Azure Portal Sandbox to test and make any UI changes that are defined in createUiDefinition.json. To make additional changes to the Azure portal experience, start by reading some documentation and copying the contents of createUiDefinition.json into the sandbox environment.

4. Package up the managed app code

The name of the final two files (mainTemplate.json and createUiDefinition.json) cannot be changed. The file names are also case-sensitive and cannot be changed at this time. Managed apps require these files to be packaged up into a zip file (where the json files must be at the root directory).

cd <repo_root_directory>/infra/managed-app
 tar -a -c -f managed-app.zip createUiDefinition.json mainTemplate.json openapi.json artifacts 

This zip file can then be uploaded to an Azure Storage location when setting up a Service Catalog Managed Application Definition.

5. Create the Service Catalog Managed App Definition

In the Azure Portal, go to Marketplace and create a Service Catalog Managed App Definition. You must provide a uri link to the uploaded managed-app.zip file as part of the creation process.

6. Deploy the managed app

You can deploy from the portal using the following steps In the Azure Portal, find and click on the managed app definition resource that was created in the previous step. A button option to Deploy from definition will be available. Click on it and proceed through the setup steps (defined by the createUiDefinitions.json file) that a consumer would experience when installing the managed app.

or you can deploy to azure Deploy to Azure