1. Introduction and Scenario
3. Creating the VM Role (step 1 and 2)
4. Pull Server
5. Resource Kit
6. PFX Repository Website
7. Creating a configuration document with encrypted content
8. Create, deploy and validate the final VM Role
9. Create a Domain Join DSC resource
10. Closing notes
In this post the VM Role Resource Definition and Resource Extension will be created. Functionality wise it will handle step 1 and 2.
At a later post the VM Role will be extended to handle the remaining steps as well.
If you don’t know what a VM Role is or you wish to deepen your understanding about it, I advise you to take a look at my colleagues’ Marc van Eijk blog series. You can find the first post here: http://blogs.technet.com/b/privatecloud/archive/2014/07/17/the-windows-azure-pack-vm-role-introduction.aspx. Marc explains the VM Role resource definition and extension in great detail.
Because there is already a lot of content about creating VM Roles I won’t go into depth in this series. I will show every step I took in creating the VM Role but I won’t elaborate on why I use a certain property types and how this reflects in the user experience, etc.
As a prerequisite you need a sysprepped Windows Server 2012 R2 VHDX file in the SCVMM library. The Image should have the latest WMF5 preview (or RTM when its released) installed. I follow Azure in deploying WMF5 preview because some of the DSC resources already require it.
The Image should have been configured with a familyname, a version and with the some tags: WindowsServer2012, R2 and WMF5. You can assign tags using PowerShell only. Run the following command replacing values with your own.
Get-SCVirtualHardDisk -Name "Srv_2012_R2_GUI_WMF5_VMRole.vhdx" | Set-SCVirtualHardDisk -Tag "WindowsServer2012","R2","WMF5" -FamilyName "Windows Server 2012 R2 GUI VMRole WMF5" -Release "188.8.131.52"
We will start building the Resource Extension. To follow along you will be needing the VM Role Authoring tool which you can download here: https://vmroleauthor.codeplex.com/
So let’s start by opening the tool.
Open the file menu and select New Windows Resource Extension Package.
Enter a name and a select a folder where to save the resource extension. Press OK.
The Resource Extension working directory is created. Modify the Publisher and press the save button.
The save action will actually create the resextpkg file. Save often as the tool is known to easily crash.
Navigate to the Resource Requirements node and remove the default OS Virtual Hard Disk Tag of Windows and add WindowsServer2012, R2 and WMF5 as valid tags.