0

I currently have a few websites that are running in IIS and they all have a virtual directory to another website called "Resources". On the resources website I have images, css, and other static type content that I share across multiple sites.

I want to replicate this using web roles. Yes they all need to be in a separate web role because they belong to different clients. I would like to just create a separate website for resources and have virtual directory from each of the other sites. Please advise if this is possible or if I need to keep these sites on a VM.

David Makogon
  • 69,407
  • 21
  • 141
  • 189
Mike
  • 37
  • 6

2 Answers2

0

You cannot attach a shared disk, since disk-attaches have exclusive leases.

The Azure File Storage service provides an SMB share (backed by Azure Storage). By attaching to the share at startup, you'd be able to take advantage of a shared folder. More info on Azure File Storage here.

You may also populate a shared-content directory on each web role instance, at startup, by downloading content from a common source (e.g. Azure blob).

Aside from those built-in mechanisms, there are any number of custom VM-based solutions.

David Makogon
  • 69,407
  • 21
  • 141
  • 189
0

Yes such a solution is possible. You can move your static resources css, images etc to azure blob storage and link it from there. Code change required. If you think you need a content delivery network CDN you can use azure CDN. See this blog post explaining it www.hanselman.com/blog/PennyPinchingVideoMovingMyWebsitesImagesToTheAzureCDNAndUsingACustomDomain.aspx

A slightly older stackoverflow question explains it too. stackoverflow.com/questions/6968011/storing-css-files-on-windows-azure

Aravind
  • 4,125
  • 1
  • 28
  • 39