Add install-unbound.ps1

This commit is contained in:
Markus Fleschutz
2022-05-22 22:35:21 +02:00
parent 21c25ac698
commit a5ff3ae02f
4 changed files with 101 additions and 11 deletions

View File

@ -19,12 +19,15 @@ try {
$PathToRepo = "$PSScriptRoot/.."
$Table = import-csv "$PathToRepo/Data/domain-names.csv"
foreach($Row in $Table) {
write-progress "Resolving $($Row.Domain) ..."
if ($IsLinux) {
$Ignore = nslookup $Row.Domain
} else {
$Ignore = resolve-dnsName $Row.Domain
if ($IsLinux) {
foreach($Row in $Table) {
write-progress "Resolving $($Row.Domain)..."
$null = dig $Row.Domain
}
} else {
foreach($Row in $Table) {
write-progress "Resolving $($Row.Domain)..."
$null = resolve-dnsName $Row.Domain
}
}
$Count = $Table.Length