I'm currently trying to architect a application to host multiple websites from a single .net core application.
Ideally, I would like to show completely different Razor pages based on the domain name the application is being accessed from.
Ideally, I would like to have my razor pages broken down into areas, where each area is associated with a different domain name. IE www.domain1.com is the domain1 area, www.domain2.com is the domain2 area, and each area has it's own index about page etc.
So if someone accesses the application from www.domain1.com/aboutus , it would direct them to the razor pages located in the Area/Domain1/Pages/AboutUs section of my application.
Similarly if my application were to receive a request to www.domain2.com/aboutus, they would see the about us page located under Area/Domain2/Pages/Aboutus.
I've been searching for hours, and I can't figure out how you accomplish this using razor pages area feature. The only information I can find is how to accomplish this using areas with vanilla MVC.
This was a pretty good example.
Different domain in the same app ASP.NET Core 2.0
I can't figure out how to accomplish the same type of thing using razor pages.