ps/Modules/Cole.PowerShell.Developer/Public/Add-OrbHostEntries.ps1

22 lines
574 B
PowerShell
Raw Normal View History

2023-05-30 22:51:22 -07:00
function Add-OrbHostEntries {
<#
.SYNOPSIS
Adds all the known ORB entries to the hosts file
.LINK
Get-KnownDeveloperHostsEntries
#>
[CmdletBinding()]
[OutputType([string])]
param()
$logLead = Get-LogLeadName
$knownHostEntries = (Get-KnownDeveloperHostsEntries)
$existingRecords = Get-Host
foreach ($entry in $knownHostEntries) {
Write-Host "$logLead : Adding hosts file with IpAddress $($entry.IpAddress) and Hostname $($entry.Hostname)"
Add-HostsFileEntry -IpAddress $entry.IpAddress -Hostname $entry.Hostname
}
}