Skip to content

Commit

Permalink
Switching to 10 chars DNS name generator instead of a default one due…
Browse files Browse the repository at this point in the history
… to reservations
  • Loading branch information
MarcoColomb0 committed Dec 11, 2023
1 parent 0d33513 commit 05804d7
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
9 changes: 8 additions & 1 deletion deployments/w11-23h2.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,14 @@ $NSGRuleName = 'apsdRDPRule'
$PublicIPAddressName = 'APSD-WC-pip'
$SubnetAddressPrefix = '192.168.77.0/24'
$VNetAddressPrefix = '192.168.0.0/16'
$DNSNameLabel = 'apsdwc'

# Generate DNS name
# Generate a 10 characters string for the DNS name
$characters = 'abcdefghijklmnopqrstuvwxyz'
$randomString = -join ($characters.ToCharArray() | Get-Random -Count 10)

# Assign the string to the variable
$DNSNameLabel = $randomString

# Logs
$LogsDate = Get-Date -format dd-MM-yyyy
Expand Down
9 changes: 8 additions & 1 deletion deployments/ws-2022.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,14 @@ $NSGRuleName = 'apsdRDPRule'
$PublicIPAddressName = 'APSD-WS-pip'
$SubnetAddressPrefix = '192.168.77.0/24'
$VNetAddressPrefix = '192.168.0.0/16'
$DNSNameLabel = 'apsdws'

# Generate DNS name
# Generate a 10 characters string for the DNS name
$characters = 'abcdefghijklmnopqrstuvwxyz'
$randomString = -join ($characters.ToCharArray() | Get-Random -Count 10)

# Assign the string to the variable
$DNSNameLabel = $randomString

# Logs
$LogsDate = Get-Date -format dd-MM-yyyy
Expand Down

0 comments on commit 05804d7

Please sign in to comment.