Hostname on Windows build agents are not fully qualified with domain
Our Linux build agents return a fully qualified hostname xyz.test.com
But Windows only returns xyz.
This seems to be a difference in the hostname os command between windows and linux.
We use the Node hostname in a lot of places and can have same hostname in 2 different domains.
Is there some way to override using "hostname"?
Maybe if os = windows instead of "hostname" os command
Execute: net config workstation | findstr /C:"Full Computer name"
Or Java code use:
InetAddress.getLocalHost().getCanonicalHostName()
Description
Hostname on Windows build agents are not fully qualified with domain
Our Linux build agents return a fully qualified hostname xyz.test.com
But Windows only returns xyz.
This seems to be a difference in the hostname os command between windows and linux.
We use the Node hostname in a lot of places and can have same hostname in 2 different domains.
Is there some way to override using "hostname"?
Maybe if os = windows instead of "hostname" os command
Execute: net config workstation | findstr /C:"Full Computer name"
Or Java code use:
InetAddress.getLocalHost().getCanonicalHostName()