Make sure to check for HOSTNAME before doing anything.