Update setupMDT.ps1

add scripts copied from the gui
This commit is contained in:
Upgrayedd 2024-08-17 21:45:48 -05:00
parent a18cd7b86e
commit fec0589cef

View file

@ -18,4 +18,20 @@ mkdir T:\DeploymentShare
#import-mdtdriver -path "MDT:\Out-of-Box Drivers" -SourcePath "T:\Drivers" -ImportDuplicates -Verbose
#update-MDTDeploymentShare -path "MDT:" -Verbose
#import-mdtoperatingsystem -path "MDT:\Operating Systems" -SourcePath "T:\Deploymentshare\Operating Systems\Windows 7 x64" -DestinationFolder "Windows 7 x64" -Verbose
#
#
#add Operating System Folder
Import-Module "C:\Program Files\Microsoft Deployment Toolkit\bin\MicrosoftDeploymentToolkit.psd1"
New-PSDrive -Name "DS001" -PSProvider MDTProvider -Root "T:\DeploymentShare"
new-item -path "DS001:\Operating Systems" -enable "True" -Name "Windows10" -Comments "For Old People" -ItemType "folder" -Verbose
#mount the windows ISO
Mount-DiskImage -ImagePath "\\SynCloud\Data\Resources\Win10_22H2_English_x64.iso" | Get-Volume
$info = Mount-DiskImage -ImagePath "\\SynCloud\Data\Resources\Win10_22H2_English_x64.iso"
$Drive = ($info | get-volume) $info
$Source = $Drive.DriveLetter+":\"
#import OS
Import-Module "C:\Program Files\Microsoft Deployment Toolkit\bin\MicrosoftDeploymentToolkit.psd1"
New-PSDrive -Name "DS001" -PSProvider MDTProvider -Root "T:\DeploymentShare"
import-mdtoperatingsystem -path "DS001:\Operating Systems\Windows10" -SourcePath $Source -DestinationFolder "Windows 10 x64" -Verbose