From 68afe7125d53fa840763d757da8bbafe6ea88b21 Mon Sep 17 00:00:00 2001 From: selmankoc Date: Mon, 16 Jun 2025 14:22:23 +0300 Subject: [PATCH] Add instructions for creating an Azure Static Web App for Blazor in deployment documentation --- .../step1-create-azure-resources.md | 1 + .../step2-configuration-application.md | 224 ++++-------------- 2 files changed, 41 insertions(+), 184 deletions(-) diff --git a/docs/en/solution-templates/layered-web-application/deployment/azure-deployment/step1-create-azure-resources.md b/docs/en/solution-templates/layered-web-application/deployment/azure-deployment/step1-create-azure-resources.md index f27af7e45f..9fb4de254b 100644 --- a/docs/en/solution-templates/layered-web-application/deployment/azure-deployment/step1-create-azure-resources.md +++ b/docs/en/solution-templates/layered-web-application/deployment/azure-deployment/step1-create-azure-resources.md @@ -184,6 +184,7 @@ To create a new Azure Web App Service, choose one of the following options: ![Create Web App](../../../../images/azure-deploy-create-web-app-5.png) {{ else }} + ### Create a new Azure Static Web App for Blazor using the Azure Portal 1. Log in to the [Azure Portal](https://portal.azure.com/). diff --git a/docs/en/solution-templates/layered-web-application/deployment/azure-deployment/step2-configuration-application.md b/docs/en/solution-templates/layered-web-application/deployment/azure-deployment/step2-configuration-application.md index 5c5daed964..87993a0af2 100644 --- a/docs/en/solution-templates/layered-web-application/deployment/azure-deployment/step2-configuration-application.md +++ b/docs/en/solution-templates/layered-web-application/deployment/azure-deployment/step2-configuration-application.md @@ -9,17 +9,25 @@ ## Step 2: Customizing the Configuration of the ABP Application -- To customize the configuration of your ABP application, modify the `ConnectionString` values in every location throughout your project. The `ConnectionString` values are stored in the `appsettings.json` files. +#### To customize the configuration of your ABP application + +- Modify the `ConnectionString` values in every location throughout your project. The `ConnectionString` values are stored in the `appsettings.json` files. This includes the following files: -{{ if UI == "MVC" && Tiered == "No" }} - **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.Web/appsettings.json** -{{else}} - **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.HttpApi.Host/appsettings.json** -{{end}} -{{if Tiered == "Yes"}} + **./src/yourapp.DbMigrator/appsettings.json** +{{ if Tiered == "No" }} +{{ if UI == "MVC" }} + **./src/yourapp.Web/appsettings.json** +{{ else if UI == "Blazor" || UI == "BlazorServer" || UI == "BlazorWebApp" }} + and **./src/yourapp.Blazor/appsettings.json** +{{ end }} +{{ if UI == "Blazor"|| UI == "NG}} + **./src/yourapp.HttpApi.Host/appsettings.json** +{{ end }} +{{ else }} + **./src/yourapp.HttpApi.Host/appsettings.json** **./src/yourapp.AuthServer/appsettings.json** -{{end}} +{{ end }} ```json "ConnectionStrings": { @@ -27,103 +35,33 @@ } ``` -{{ if UI == "MVC" }} - -{{if Tiered == "No"}} - Modify the **yourapp.Web** URL in every location throughout your project, especially within the **./src/yourapp.Web/appsettings.json** and **./src/yourapp.DbMigrator/appsettings.json** files, to match your Azure Web App Service URL. -```json - "App": { - "SelfUrl": "https://yourapp.azurewebsites.net" - } -``` - -{{else}} - -- Modify the **yourapp.Web** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.Web/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** , **./src/yourapp.HttpApi.Host/appsettings.json** and **./src/yourapp.AuthServer/appsettings.json** - -```json -"App": { - "SelfUrl": "https://yourapp.azurewebsites.net" -} -``` - -- Modify the **yourapp.ApiHost** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.HttpApi.Host/appsettings.json** , **./src/yourapp.Web/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.AuthServer/appsettings.json** - -```json -"App": { - "SelfUrl": "https://yourapp-apihost.azurewebsites.net" -} -``` - -- Modify the **yourapp.AuthServer** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.Web/appsettings.json** , **./src/yourapp.AuthServer/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.HttpApi.Host/appsettings.json** - -```json -"App": { - "SelfUrl": "https://yourapp-authserver.azurewebsites.net" -} -``` - -- Modify the **Redis__Configuration** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.Web/appsettings.json** , **./src/yourapp.AuthServer/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.HttpApi.Host/appsettings.json** - -```json -"Redis": { - "Configuration": "redis-abpdemo.redis.cache.windows.net:6380,password={yourpassword},ssl=true,abortConnect=False" - }, -``` - -{{end}} - -{{ else if UI == "NG" }} - -- Modify the **`localhost:4200`** in every location throughout your project. - - This includes the following files: - - **./angular/src/environments/environment.prod.ts** , **./aspnet-core/src/yourapp.DbMigrator/appsettings.json** and **./aspnet-core/src/yourapp.HttpApi.Host/appsettings.json** - -```typescript - application: { - baseUrl: 'https://yourapp.azurestaticapps.net' - } -``` - -- Modify the **yourapp.HttpApi.Host** URL in every location throughout your project. - - This includes the following files: - - **./angular/src/environments/environment.prod.ts** , **./aspnet-core/src/yourapp.DbMigrator/appsettings.json** and **./aspnet-core/src/yourapp.HttpApi.Host/appsettings.json** - -```json - "App": { - "SelfUrl": "https://yourApiHost.azurewebsites.net" - } -``` - -{{ else if UI == "Blazor" }} - -- Modify the **yourapp.Blazor** URL in every location throughout your project. - This includes the following files: - - **./src/yourapp.Blazor/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.HttpApi.Host/appsettings.json** + **./src/yourapp.DbMigrator/appsettings.json** +{{ if Tiered == "No" }} +{{ if UI == "MVC" }} + **./src/yourapp.Web/appsettings.json** +{{ else if UI == "Blazor" || UI == "BlazorServer" || UI == "BlazorWebApp" }} + and **./src/yourapp.Blazor/appsettings.json** +{{ else }} + Modify the **`localhost:4200`** in every location throughout your project. + **./angular/src/environments/environment.prod.ts** +{{ end }} +{{ if UI == "Blazor"|| UI == "NG}} + **./src/yourapp.HttpApi.Host/appsettings.json** +{{ end }} +{{ else }} +{{ if UI == "MVC" }} + **./src/yourapp.Web/appsettings.json** +{{ else if UI == "Blazor" || UI == "BlazorServer" || UI == "BlazorWebApp" }} + and **./src/yourapp.Blazor/appsettings.json** +{{ else }} + Modify the **`localhost:4200`** in every location throughout your project. + **./angular/src/environments/environment.prod.ts** +{{ end }} + **./src/yourapp.AuthServer/appsettings.json** ```json "App": { @@ -131,84 +69,6 @@ } ``` -- Modify the **yourapp.HttpApi.Host** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.Blazor/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.HttpApi.Host/appsettings.json** - -```json - "App": { - "SelfUrl": "https://yourApiHost.azurewebsites.net" - } -``` - -{{ else }} - -{{if Tiered == "No"}} - -- Modify the **yourapp.Web** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.Blazor/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.HttpApi.Host/appsettings.json** - -```json -"App": { - "SelfUrl": "https://yourapp.azurewebsites.net" -} -``` - -- Modify the **yourapp.ApiHost** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.HttpApi.Host/appsettings.json** , **./src/yourapp.Blazor/appsettings.json** and **./src/yourapp.DbMigrator/appsettings.json** - -```json -"App": { - "SelfUrl": "https://yourapp-apihost.azurewebsites.net" -} -``` - -{{else}} - -- Modify the **yourapp.Web** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.Blazor/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** , **./src/yourapp.HttpApi.Host/appsettings.json** and **./src/yourapp.AuthServer/appsettings.json** - -```json -"App": { - "SelfUrl": "https://yourapp.azurewebsites.net" -} -``` - -- Modify the **yourapp.ApiHost** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.HttpApi.Host/appsettings.json** , **./src/yourapp.Blazor/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.AuthServer/appsettings.json** - -```json -"App": { - "SelfUrl": "https://yourapp-apihost.azurewebsites.net" -} -``` - -- Modify the **yourapp.AuthServer** URL in every location throughout your project. - - This includes the following files: - - **./src/yourapp.Blazor/appsettings.json** , **./src/yourapp.AuthServer/appsettings.json** , **./src/yourapp.DbMigrator/appsettings.json** and **./src/yourapp.HttpApi.Host/appsettings.json** - -```json -"App": { - "SelfUrl": "https://yourapp-authserver.azurewebsites.net" -} -``` - - Modify the **Redis__Configuration** URL in every location throughout your project. This includes the following files: @@ -220,11 +80,7 @@ "Configuration": "redis-abpdemo.redis.cache.windows.net:6380,password={yourpassword},ssl=true,abortConnect=False" }, ``` - -{{end}} - -{{end}} - +{{ end }} ## What's next?