mirror of
https://github.com/actions/runner-images-sangeeth.git
synced 2025-12-20 06:29:50 +00:00
[Windows] Set the dynamic port range to start at port 49152 and to end at the 65536 (16384 ports) (#1442)
* set the dynamic port range * update pester test * update context about VS installer * update dynamicports pester test
This commit is contained in:
committed by
GitHub
parent
ad2409dbfa
commit
ba17c75613
@@ -32,10 +32,28 @@ Describe "ContainersFeature" {
|
||||
}
|
||||
|
||||
Describe "DiskSpace" {
|
||||
it "The image has enough disk space"{
|
||||
It "The image has enough disk space"{
|
||||
$availableSpaceMB = [math]::Round((Get-PSDrive -Name C).Free / 1MB)
|
||||
$minimumFreeSpaceMB = 18 * 1024
|
||||
|
||||
$availableSpaceMB | Should -BeGreaterThan $minimumFreeSpaceMB
|
||||
}
|
||||
}
|
||||
|
||||
Describe "DynamicPorts" {
|
||||
It "Test TCP dynamicport start=49152 num=16384" {
|
||||
$tcpPorts = Get-NetTCPSetting | Where-Object {$_.SettingName -ne "Automatic"} | Where-Object {
|
||||
$_.DynamicPortRangeStartPort -ne 49152 -or $_.DynamicPortRangeNumberOfPorts -ne 16384
|
||||
}
|
||||
|
||||
$tcpPorts | Should -BeNullOrEmpty
|
||||
}
|
||||
|
||||
It "Test UDP dynamicport start=49152 num=16384" {
|
||||
$udpPorts = Get-NetUDPSetting | Where-Object {
|
||||
$_.DynamicPortRangeStartPort -ne 49152 -or $_.DynamicPortRangeNumberOfPorts -ne 16384
|
||||
}
|
||||
|
||||
$udpPorts | Should -BeNullOrEmpty
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user