Desired State Configuration is mostly awesome…

But, sometimes you can’t use it!

As i’m working on my script for Rebuild conf. I’m facing terribly issues with Exchange 2013 installation with DSC. I will show you how you can “install” Exchange 2013 remotely mostly with DSC..

First of all, you need to install Windows features and roles.. this is the easy part !

After that you need to install a package as a prerequite.

And this is where things are getting worst… You can’t use Package resource, as you need to execute the install with some administrators rights.

So i came up with this, after having enabled CredSSP for WinRM.

The idea was to use delegation authority to be able to use Administrator account for installation. It works great… but. But Exchange 2013 installation, try to enable WSMAN for IIS with a function called Configure-WSmanIISHosting during his installation and it breaks the CIM Session used by DSC.

So finally, after all theses improvements with PowerShell, DSC, remoting and everything else. You still need the old good PSexec outside any workflows, DSC or WinRM sessions!

It’s ugly, and i don’t like this solution.

This is sad, and i bet it’s the same for SQL Server, i don’t have time to test it currently, maybe you have already tried that ?

Maybe you have reached the goal of installing Exchange remotely through a WinRM or CIM Session ! Say it, i’m sure there is a way, i’m not good enough with this product… i know 🙁