# encoding: ascii
# api: powershell
# title: test
# description: test
# version: 0.1
# type: module
# author: teste
# license: CC0
# x-poshcode-id: 6452
# x-archived: 2016-07-27T03:05:36
# x-published: 2016-07-21T15:29:00
#
#
#region PREREQUISITES

    # Variables
    Get-VM
    $password = ConvertTo-SecureString -AsPlainText -Force -String 'Pa$$w0rd'

    $iso_X = 'C:\depot\iso_x\en_windows_server_2016_technical_preview_4_x64_dvd_7258292\'
    $VirtualHardDiskPath = (Get-VMHost).VirtualHardDiskPath 

    # Nano creation module (from WS 2016 ISO) 
    Import-Module "C:\NanoServer_TP4\NanoServerImageGenerator.psm1 "

#endregion

#region  NANO1 

    # GEN 1 VM (Workgroup)

    $nanoName = 'sea-nano11'
    $nanoHardDisk = "$VirtualHardDiskPath\$nanoName.vhd"

    if (Test-Path $nanoHardDisk) {
      Get-ChildItem $nanoHardDisk | Remove-Item -Confirm
    }
