After reading Orchard CMS I thought it would be possible to run Orchard on .NET 4.5 Windows Server 2012. These are the steps for running Orchard CMS on Windows Azure Server 2012 .NET 4.5
Although running Orchard on .NET 4.5 is not support, I did not run into any problems after you do some modification to the Orchard project. So here we go±
Running Orchard CMS on Windows Azure Server 2012 .NET 4.5
Set the target to .NET 4.5 Framework
- Open Orchard.Azure.sln in Visual Studio 2012
- rightclick the Orchard.Azure.Web project
- select properties
- go to the Application tab
- select “.NET Framework 4.5″ in “Target Framework”
- click YES on the Target Framework Change
- Repeat these steps for Orchard.Azure project
Set target to Windows Server 2012
Set the osFamily parameter in ServiceConfiguration.cscfg in Orchard.Azure.CloudService to 3 (=Windows Server 2012)
Upgrade the Windows Azure SDK to 1.8
- Install the Windows Azure SDK 1.8 using the Web Platform installer
- In Visual Studio 2012 rightclick Orchard.Azure.CloudService
- select properties
- select the Application tab
- click the upgrade button
- wait for the upgrade to finish
You now have upgraded the tools, but not all reference are set correctly, so we are going to fix that:
- goto the Orchard.Azure project in the Orchard.Azure solution
- delete the reference
- Microsoft.WindowsAzure.Diagnostics
- Microsoft.WindowsAzure.ServiceRunTime
- Microsoft.WindowsAzure.StorageClient
- Add the reference again, but now the files from version 1.8 that are in C:\Program Files\Microsoft SDKs\Windows Azure\.NET SDK\2012-10\ref
- goto the Orchard.Azure.Web project in the Orchard.Azure solution
- Check if these refer to: C:\Program Files\Microsoft SDKs\Windows Azure\.NET SDK\2012-10\ref
- Microsoft.WindowsAzure.Configuration
- Microsoft.WindowsAzure.Diagnostics
- Microsoft.WindowsAzure.ServiceRunTime
- Microsoft.WindowsAzure.StorageClient
- If not: delete the reference and add the reference again, but now the files from version 1.8 that are in C:\Program Files\Microsoft SDKs\Windows Azure\.NET SDK\2012-10\ref
Now you have a working Orchard 1.6 CMS that is able to run on Azure’s Windows Server 2012 and .NET 4.5 using the latest Azure SDK.
Happy publishing :-)
Interesting thanks,
Actually what is the interest going for W2K12 rather than 2K8R2 which is well known ?
For example if you want to build a module that needs .NET 4.5
Have you tried to deploy Orchard via TFS into Windows Azure Websites? Having build issues now where it can’t find the Lib directory dlls.
I’m not sure if I installed Orchard on Azure Websites via TFS. What is the error message that you get? It seems to me that you didn’t include the lib files as described in this post, please check this.
The lib files are in the \lib dir, where \ is the root of your solutionfolder.