|
|
|
@ -5,10 +5,6 @@ echo "GPLv3"
|
|
|
|
|
|
|
|
|
|
### Considered as finished. Need improvement VM side.
|
|
|
|
|
|
|
|
|
|
### Define vars
|
|
|
|
|
|
|
|
|
|
$scripts_path = d:\scripts
|
|
|
|
|
|
|
|
|
|
### Adding SRV-01
|
|
|
|
|
|
|
|
|
|
echo "Adding and configuring SRV-01"
|
|
|
|
@ -18,10 +14,10 @@ $Lettre = Mount-VHD -Path "d:\VHD\SRV-01.VHDx" -PassThru | Get-Disk | Get-Partit
|
|
|
|
|
$DriveLetter = $Lettre.DriveLetter
|
|
|
|
|
$drive = $DriveLetter + ":"
|
|
|
|
|
New-Item -Path "${Driveletter}:\conf\" -Name "Base" -ItemType "directory"
|
|
|
|
|
Copy-Item ${scripts_path}\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item ${scripts_path}\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
Copy-Item D:\Scripts\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item D:\Scripts\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
mkdir "${Driveletter}:\Tools\Scripts"
|
|
|
|
|
Copy-item ${scripts_path}\Guests\SRV-01.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
Copy-item d:\Scripts\Guests\SRV-01.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
|
|
|
|
|
Dismount-VHD d:\VHD\SRV-01.vhdx
|
|
|
|
|
|
|
|
|
@ -51,10 +47,10 @@ $Lettre = Mount-VHD -Path "d:\VHD\SRV-03.VHDx" -PassThru | Get-Disk | Get-Partit
|
|
|
|
|
$DriveLetter = $Lettre.DriveLetter
|
|
|
|
|
$drive = $DriveLetter + ":"
|
|
|
|
|
New-Item -Path "${Driveletter}:\conf\" -Name "Base" -ItemType "directory"
|
|
|
|
|
Copy-Item ${scripts_path}\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item ${scripts_path}\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
Copy-Item D:\Scripts\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item D:\Scripts\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
mkdir "${Driveletter}:\Tools\Scripts"
|
|
|
|
|
Copy-item ${scripts_path}\Guests\SRV-03.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
Copy-item d:\Scripts\Guests\SRV-03.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
|
|
|
|
|
Dismount-VHD d:\VHD\SRV-03.vhdx
|
|
|
|
|
|
|
|
|
@ -86,10 +82,10 @@ $Lettre = Mount-VHD -Path "d:\VHD\RTR-01.VHDx" -PassThru | Get-Disk | Get-Partit
|
|
|
|
|
$DriveLetter = $Lettre.DriveLetter
|
|
|
|
|
$drive = $DriveLetter + ":"
|
|
|
|
|
New-Item -Path "${Driveletter}:\conf\" -Name "Base" -ItemType "directory"
|
|
|
|
|
Copy-Item ${scripts_path}\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item ${scripts_path}\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
Copy-Item D:\Scripts\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item D:\Scripts\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
mkdir "${Driveletter}:\Tools\Scripts"
|
|
|
|
|
Copy-item ${scripts_path}\Guests\RTR-01.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
Copy-item d:\Scripts\Guests\RTR-01.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
|
|
|
|
|
Dismount-VHD d:\VHD\RTR-01.vhdx
|
|
|
|
|
|
|
|
|
@ -123,10 +119,10 @@ $Lettre = Mount-VHD -Path "d:\VHD\RTR-02.VHDx" -PassThru | Get-Disk | Get-Partit
|
|
|
|
|
$DriveLetter = $Lettre.DriveLetter
|
|
|
|
|
$drive = $DriveLetter + ":"
|
|
|
|
|
New-Item -Path "${Driveletter}:\conf\" -Name "Base" -ItemType "directory"
|
|
|
|
|
Copy-Item ${scripts_path}\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item ${scripts_path}\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
Copy-Item D:\Scripts\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item D:\Scripts\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
mkdir "${Driveletter}:\Tools\Scripts"
|
|
|
|
|
Copy-item ${scripts_path}\Guests\RTR-02.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
Copy-item d:\Scripts\Guests\RTR-02.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
|
|
|
|
|
Dismount-VHD d:\VHD\RTR-02.vhdx
|
|
|
|
|
|
|
|
|
@ -160,10 +156,10 @@ $Lettre = Mount-VHD -Path "d:\VHD\RTR-03.VHDx" -PassThru | Get-Disk | Get-Partit
|
|
|
|
|
$DriveLetter = $Lettre.DriveLetter
|
|
|
|
|
$drive = $DriveLetter + ":"
|
|
|
|
|
New-Item -Path "${Driveletter}:\conf\" -Name "Base" -ItemType "directory"
|
|
|
|
|
Copy-Item ${scripts_path}\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item ${scripts_path}\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
Copy-Item D:\Scripts\Unattend\FullUnattend-srv.xml -Destination "$Drive\Windows\Panther\Unattend.xml"
|
|
|
|
|
Copy-Item D:\Scripts\deploy.cmd -Destination "${Driveletter}:\conf\deploy.cmd"
|
|
|
|
|
mkdir "${Driveletter}:\Tools\Scripts"
|
|
|
|
|
Copy-item ${scripts_path}\Guests\RTR-03.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
Copy-item d:\Scripts\Guests\RTR-03.ps1 "${Driveletter}:\Tools\scripts\boot.ps1"
|
|
|
|
|
|
|
|
|
|
Dismount-VHD d:\VHD\RTR-03.vhdx
|
|
|
|
|
|
|
|
|
|