I need to find out a way of how to get the AD bound computer name of a computer via bash script.
Reason being that ive recently deployStudio deployed an image to a few hundred clients only to realise that the bind-name is not reflected into the LocalHostName, HostName or ComputerName values in OSX. What id like to do is deploy a script/command via ARD that will grab the AD compName then:
scutil --set ComputerName $ADCompName
scutil --set LocalHostName $ADCompName
scutil --set HostName $ADCompName
Thanks for all assistance experts.