diff --git a/src/apps/Elsa.ServerAndStudio.Web/Pages/_Host.cshtml b/src/apps/Elsa.ServerAndStudio.Web/Pages/_Host.cshtml index 1c146068a..c2217d30d 100644 --- a/src/apps/Elsa.ServerAndStudio.Web/Pages/_Host.cshtml +++ b/src/apps/Elsa.ServerAndStudio.Web/Pages/_Host.cshtml @@ -2,7 +2,7 @@ @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers @inject IConfiguration Configuration; @{ - var baseUrl = $"{Request.Scheme}://{Request.Host}"; + var baseUrl = Configuration["Hosting:BaseUrl"]!; var apiUrl = baseUrl + Url.Content("~/elsa/api"); var basePath = Configuration["Hosting:BasePath"]!; } diff --git a/src/apps/Elsa.ServerAndStudio.Web/appsettings.json b/src/apps/Elsa.ServerAndStudio.Web/appsettings.json index d9f27f46c..13e1398d5 100644 --- a/src/apps/Elsa.ServerAndStudio.Web/appsettings.json +++ b/src/apps/Elsa.ServerAndStudio.Web/appsettings.json @@ -18,6 +18,7 @@ "MySql": "Server=localhost;Database=elsa;Uid=user;Pwd=password;" }, "Hosting": { + "BaseUrl": "https://localhost:5001", "BasePath": "" }, "Identity": {