Description of the problem: beah-beaker-backend fails to set HOSTNAME configuration variable by default and emits a warning message. Version-Release number of selected component (if applicable): systemd-208-11.el7.x86_64 beah-0.7.3-1.el7eng.noarch How reproducible: Always Steps to Reproduce: 1. Run a recipe in beaker 2. Check the output of "systemctl status beah-beaker-backend" Actual behavior: # systemctl status -l beah-beaker-backend | grep -i warning || echo OK Jun 09 01:06:38 myhost beah-beaker-backend[1839]: --- WARNING: Value for DEFAULT.HOSTNAME (None) is not an string. Expected behavior: # systemctl status -l beah-beaker-backend | grep -i warning || echo OK OK Additional Information: beakerlc.py tries to obtain hostname via "HOSTNAME" env: def defaults(): ... d.update({ ... 'HOSTNAME':os.getenv('HOSTNAME'), However, os.getenv('HOSTNAME') returns empty. Using the output of '/bin/hostname' instead solves the problem. Or there might be better systemd-way to get the equivalent information.
We've had to do some intricate dances in kickstart files to get the correct hostname information during %post, but I wasn't previously aware of troubles with HOSTNAME not being set when beah starts up. We'll investigate further.
HOSTNAME (the environment variable) is a bash-ism, it was always previously available because SysV init does everything through bash. However with systemd bash is removed from the equation entirely. It should probably be using socket.gethostname() as the default, although it actually doesn't matter since HOSTNAME (the beah config option) is not used for anything important anymore.
On Gerrit: http://gerrit.beaker-project.org/3132
Beah 0.7.5 has been released on beaker-project.org.