Closed aristotelos closed 5 months ago
This is probably because the membership script uses $env:COMPUTERNAME
which returns a name truncated to 15 characters. A better alternative is [System.Net.Dns]::GetHostName()
which seems to return the correct name.
SUMMARY
The
microsoft.ad.membership
fails if the computer name is longer than 15 characters.ISSUE TYPE
COMPONENT NAME
microsoft.ad.membership
ANSIBLE VERSION
COLLECTION VERSION
CONFIGURATION
OS / ENVIRONMENT
Windows 10.
STEPS TO REPRODUCE
Join a computer to a domain using the following task. Use a computer name that is longer than 15 characters:
EXPECTED RESULTS
The step should succeed without changes because of idempotency.
ACTUAL RESULTS