In a multitnenant deployment of Orchard, request are routed to the correct tenant by the hostname in the http request. However, when requesting resources from the Media folder, the tenant name must also appear in the URL.
Say I have two tenants:
- HostA - hostA.sample.com
- HostB - hostB.sample.com
I create default content that I want to display in both tenant sites. The content references branded images stored in each tenant's Media folder. Now, I must fixup the links to the images when I move the content from HostA to HostB because the Image in the
content would look something like:
<img src="/Media/HostA/BrandedImage.png />
If I use import/export to move my content from HostA to HostB, I now have an additional manual step to fix up the img src attributes since the tenant name is in the media path as well as the host name.
I simplified my example, but in my reality I have dozens of pages that only differ in the images displayed. I want to simply import my content each time I set up a new tenant and upload custom images for each tenant and have it displayed correctly. Is
there a way to avoid this manual step of editing the img src paths?