def hostname(self, newname=None):
        if newname:
            resp, el = self.command("hostname %s" % (newname,))
            if el:
                return True
            else:
                raise ControllerError, "could not set hostname"
        else:
            resp, el = self.command("hostname")
            if el:
                return resp.strip()
            else:
                raise ControllerError, "could not get hostname"
Get the hostname.
dataset/ETHPy150Open kdart/pycopia/QA/pycopia/QA/ssh_controller.py/ShellController.hostname