code: def console_type(self, console_type):
          
  
          if console_type != self._console_type:
              # get a new port if the console type change
              self._manager.port_manager.release_tcp_port(self._console, self._project)
              if console_type == "vnc":
                  # VNC is a special case and the range must be 5900-6000
                  self._console = self._manager.port_manager.get_free_tcp_port(self._project, 5900, 6000)
              else:
                  self._console = self._manager.port_manager.get_free_tcp_port(self._project)
  
          self._console_type = console_type
          log.info("{module}: '{name}' [{id}]: console type set to {console_type}".format(module=self.manager.module_name,
                                                                                          name=self.name,
                                                                                          id=self.id,
                                                                                          console_type=console_type))
docs: Sets the console type for this node.
  
          :param console_type: console type (string)