The Microsoft Dynamics NAV Provisioning Tools for Windows Azure have been designed to provide an end-to-end scenario for deploying Microsoft Dynamics NAV on the Windows Azure. However, because the provisioning tools are implemented in Windows PowerShell scripts, you can adapt them to other cloud services or on-premise installations.

This topic provides an overview of the work that is required to modify the provisioning tools for deploying Microsoft Dynamics NAV on cloud services and virtual machines that are not on Windows Azure.

Preparing the Virtual Machines

The virtual machines on the cloud service must meet the following requirements:

Modifying the Provisioning Tool Scripts

The provisioning tools are located in the WindowsPowerShellScripts\Cloud folder on the Microsoft Dynamics NAV installation media (DVD). The Cloud folder includes several subfolders where the different Windows PowerShell scripts are organized according to their function. Most of the scripts do not have any dependencies on Windows Azure so that they can be reused in other environments without modification. You perform most of the modifications on the scripts in the Cloud\NAVRemoteAdministrationSamples folder and Cloud\NAVRemoteAdministration\Azure folder of the provisioning tools.

The Cloud\NAVRemoteAdministrationSamples folder contains the following files that you must modify:

  • Install-NAVBox.ps1
  • HowTo-CreateAzureVM.ps1
  • HowTo-InstallNAVOnVM.ps1
  • HowTo-AddNAVInstance.ps1
  • HowTo-OpenFirewallPort.ps1
  • HowTo-SetAzureVMSize.ps1
  • HowTo-UploadFilesToVM.ps1

The "HowTo” scripts import and call additional scripts from the Cloud\NAVRemoteAdministration folder and its subfolders. Most of the scripts in this folder are generic and should not be modified. However, some of the scripts have dependencies Windows Azure for doing tasks like creating the network, the virtual machines, and the physical storage where the virtual machines are installed. The Window Azure-specific scripts are all located in the Cloud\NAVRemoteAdministration\Azure folder and include the following:

  • New-NAVAzureBaseVM.ps1
  • New-NAVAzureDataDisk.ps1
  • Copy-VhdFileToAzureStorage.ps1
  • Mount-VhdFileToAzureVM.ps1
  • Dismount-VhdFileFromAzureVM.ps1
  • Wait-VMReadyState.ps1
  • Remove-NAVAzureVM.ps1
  • New-AzureVhdDisk.ps1
  • New-AzureVirtualNetwork.ps1
  • Test-AzureAffinityGroup.ps1
  • Test-AzureVirtualNetwork.ps1

Replace these scripts with scripts that perform similar tasks on your environment.

The scripts in the Cloud\NAVRemoteAdministration\Azure folder are very specific to Windows Azure. The API for your cloud service provider may require a different structure of the scripts. However, the high-level concepts will be similar.

See Also