Skip to content

Commit

Permalink
fixing automatic port definition statement structure
Browse files Browse the repository at this point in the history
  • Loading branch information
ShutdownRepo committed Sep 27, 2023
1 parent 3b9df15 commit 20df3f6
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions exegol/model/ContainerConfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -530,9 +530,11 @@ def configureDesktop(self, desktop_config: str):
logger.critical(f"Your configuration is invalid, please use the following format:[green]mode:host:port[/green]")

if self.__desktop_port is None:
_desktop_host = self.__desktop_host if _host_set_by_user else None
logger.debug(f"Desktop port automatically set for host {_desktop_host}")
self.__desktop_port = self.__findAvailableRandomPort(_desktop_host)
logger.debug(f"Desktop port will be set automatically")
if _host_set_by_user:
self.__desktop_port = self.__findAvailableRandomPort(self.__desktop_host)
else:
self.__desktop_port = self.__findAvailableRandomPort()

def __disableDesktop(self):
"""Procedure to disable exegol desktop feature"""
Expand Down

0 comments on commit 20df3f6

Please sign in to comment.