I have ASP.NET Core applications hosted on Azure App Services as two virtual applications in the same App Services instance. The main site app is hosted at /
and the blog application at /blog
. I would like to use AspNetCoreModuleV2 with the InProcess hosting model. However, it fails to start up and I see this error in the event log:
<Event>
<System>
<Provider Name="IIS AspNetCore Module V2"/>
<EventID>1008</EventID>
<Level>1</Level>
<Task>0</Task>
<Channel>Application</Channel>
...
</System>
<EventData>
<Data>
Only one inprocess application is allowed per IIS application pool. Please assign the application '/LM/W3SVC/170746742/ROOT/api' to a different IIS application pool.
</Data>
<Data>Process Id: 20236.</Data>
<Data>
File Version: 12.2.18296.0. Description: IIS ASP.NET Core Module V2. Commit: 61f1a70784dc0a32cf98f8ddd169c0293b0390ab
</Data>
</EventData>
</Event>
How can I run multiple virtual applications in App Services using the InProcess hosting model?
You can deploy multiple separate 'WebApps' under an 'App Service Plan'. All those WebApps (/websites) will have their own separate default domain (FQDN) and also you can set custom domain for each of those WebApps.
Azure App Service on Windows Server uses Internet Information Services (IIS).
In the app's left menu, select Configuration > General settings. Here, you can configure some common settings for the app. Some settings require you to scale up to higher pricing tiers. Stack settings: The software stack to run the app, including the language and SDK versions.
Open Visual Studio and then select Create a new project. In Create a new project, find, and select ASP.NET Core Web App, then select Next. In Configure your new project, name the application MyFirstAzureWebApp, and then select Next.
Nope. The error info in the event log has answered,
<EventData> <Data>
Only one inprocess application is allowed per IIS application pool. Please assign the application '/LM/W3SVC/170746742/ROOT/api' to a different IIS application pool.</Data>
In your scenario for running multiple virtual applications in the same Azure WebApp, only one app can run in the hosting model as in-process
, others can be configured in web.config
file as out-of-process
via Kestrel
, as below, please see more details at here ASP.NET Core Module
.
Note: hostingModel="OutOfProcess"
<?xml version="1.0" encoding="utf-8"?> <configuration> <location path="." inheritInChildApplications="false"> <system.webServer> <handlers> <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" /> </handlers> <aspNetCore processPath="dotnet" arguments=".\MyApp.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="OutOfProcess" /> </system.webServer> </location> </configuration>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With