code: def get_my_hostname(self, split_hostname_on_first_period=False):
          
  
          hostname = self.init_config.get("os_host") or self.hostname
          if split_hostname_on_first_period:
              hostname = hostname.split('.')[0]
  
          return hostname
docs: Returns a best guess for the hostname registered with OpenStack for this host