I tried joining the domain from a firstboot module in Fedora. It fails unless I set $LOGNAME. It doesn't matter *what* I set it to, as long as it's not empty.