This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
app.UseOrchardCore(a => a.Run(async context => | |
{ | |
// ShellSettings provide the tenant's configuration. | |
var shellSettings = context.RequestServices.GetRequiredService<ShellSettings>(); | |
// Read the tenant-specific custom setting. | |
var customSetting = shellSettings.Configuration["CustomSetting"]; | |
// Resolve all registered IMessageProvider services. | |
var messageProviders = context.RequestServices.GetServices<IMessageProvider>(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"CustomerA": { | |
"State": "Running", | |
"RequestUrlHost": null, | |
"RequestUrlPrefix": "customer-a", | |
"CustomSetting": "Custom setting for Customer A", | |
"Features": [ "RemoteIp" ] | |
}, | |
"CustomerB": { | |
"State": "Running", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Linq; | |
using System.Threading.Tasks; | |
using Microsoft.AspNetCore.Builder; | |
using Microsoft.AspNetCore.Hosting; | |
using Microsoft.AspNetCore.Http; | |
using Microsoft.Extensions.DependencyInjection; | |
using OrchardCore.Environment.Shell; | |
namespace MultiTenantApp | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Microsoft.AspNetCore.Builder; | |
using Microsoft.AspNetCore.Hosting; | |
using Microsoft.Extensions.DependencyInjection; | |
namespace AngularWidgetsDemo | |
{ | |
public class Startup | |
{ | |
public void ConfigureServices(IServiceCollection services) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
npm i -g @angular/cli | |
ng new ClientApp --prefix custom |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ClientApp | |
ng add @angular/elements |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ClientApp | |
npm install | |
ng build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add-Type -AssemblyName System.IO.Compression.FileSystem | |
Invoke-WebRequest -Uri https://github.com/nitayneeman/made-with-love/archive/release/v1.1.0.zip -OutFile ./ClientApp.zip | |
[System.IO.Compression.ZipFile]::ExtractToDirectory("c:\Code\Orchard Core and Angular\AngularWidgetsDemo\ClientApp.zip", "c:\Code\Orchard Core and Angular\AngularWidgetsDemo") | |
Rename-Item made-with-love-master ClientApp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dotnet new web --name "AngularWidgetsDemo" | |
cd "AngularWidgetsDemo" | |
dotnet add package "OrchardCore.Application.Cms.Targets" --version 1.0.0-beta2-* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dotnet new -i OrchardCore.Cms.Templates::1.0.0-beta2-* |