Delete Allfiles/Interactive Lab Simulation Files/08 directory

This commit is contained in:
staleycyn 2025-06-11 18:35:22 -07:00 committed by GitHub
parent 86ded7d191
commit 39ae882594
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 0 additions and 51 deletions

View File

@ -1,23 +0,0 @@
$rgName = 'az104-08-rg02'
$vmssName = 'az10408vmss0'
$vmss = Get-AzVmss `
-ResourceGroupName $rgName `
-VMScaleSetName $vmssName
$publicSettings = @{
"fileUris" = (,"https://raw.githubusercontent.com/Azure-Samples/compute-automation-configurations/master/prepare_vm_disks.ps1");
"commandToExecute" = "powershell -ExecutionPolicy Unrestricted -File prepare_vm_disks.ps1"
}
Add-AzVmssExtension -VirtualMachineScaleSet $vmss `
-Name "customScript" `
-Publisher "Microsoft.Compute" `
-Type "CustomScriptExtension" `
-TypeHandlerVersion 1.8 `
-Setting $publicSettings
# Update the scale set and apply the Custom Script Extension to the VM instances
Update-AzVmss `
-ResourceGroupName $rgName `
-Name $vmssName `
-VirtualMachineScaleSet $vmss

View File

@ -1,18 +0,0 @@
{
"type": "Microsoft.Compute/virtualMachines/extensions",
"name": "az104-08-vm1/customScriptExtension",
"apiVersion": "2018-06-01",
"location": "[resourceGroup().location]",
"dependsOn": [
"az104-08-vm1"
],
"properties": {
"publisher": "Microsoft.Compute",
"type": "CustomScriptExtension",
"typeHandlerVersion": "1.7",
"autoUpgradeMinorVersion": true,
"settings": {
"commandToExecute": "powershell.exe Install-WindowsFeature -name Web-Server -IncludeManagementTools && powershell.exe remove-item 'C:\\inetpub\\wwwroot\\iisstart.htm' && powershell.exe Add-Content -Path 'C:\\inetpub\\wwwroot\\iisstart.htm' -Value $($env:computername)"
}
}
},

View File

@ -1,3 +0,0 @@
powershell.exe Install-WindowsFeature -name Web-Server -IncludeManagementTools
powershell.exe Remove-Item -Path 'C:\inetpub\wwwroot\iisstart.htm'
powershell.exe Add-Content -Path 'C:\inetpub\wwwroot\iisstart.htm' -Value "$env:computername"

View File

@ -1,7 +0,0 @@
New-StoragePool -FriendlyName storagepool1 -StorageSubsystemFriendlyName "Windows Storage*" -PhysicalDisks (Get-PhysicalDisk -CanPool $true)
New-VirtualDisk -StoragePoolFriendlyName storagepool1 -FriendlyName virtualdisk1 -Size 2046GB -ResiliencySettingName Simple -ProvisioningType Fixed
Initialize-Disk -VirtualDisk (Get-VirtualDisk -FriendlyName virtualdisk1)
New-Partition -DiskNumber 4 -UseMaximumSize -DriveLetter Z