Merge "Change TCP port value"
This commit is contained in:
commit
2462c55035
@ -182,5 +182,6 @@ class Serial:
|
||||
"uartbase": "0x3F8",
|
||||
"uartport": "4",
|
||||
"uartmode": "tcpserver",
|
||||
# The port number of the ssh connection of controller-1 wil be added to the uartpath so 2 deployments don't have the same TCP port.
|
||||
"uartpath": 10000,
|
||||
}
|
||||
|
@ -379,6 +379,10 @@ def create_lab(m_vboxoptions):
|
||||
disk_sizes = item['disks'][no_disks]
|
||||
vboxmanage.vboxmanage_createmedium(node, disk_sizes,
|
||||
vbox_home_dir=m_vboxoptions.vbox_home_dir)
|
||||
|
||||
if "controller-0" in node:
|
||||
serial_config[0]['uartpath'] = serial_config[0]['uartpath'] + int(m_vboxoptions.nat_controller0_local_ssh_port)
|
||||
|
||||
vboxmanage.vboxmanage_modifyvm(
|
||||
node,
|
||||
{
|
||||
@ -785,7 +789,10 @@ def serial_prompt_mode(mode):
|
||||
def _connect_to_serial(virtual_machine=None):
|
||||
if not virtual_machine:
|
||||
virtual_machine = V_BOX_OPTIONS.labname + "-controller-0"
|
||||
sock = serial.connect(virtual_machine, 10000, getpass.getuser())
|
||||
|
||||
port = 10000 + int(V_BOX_OPTIONS.nat_controller0_local_ssh_port)
|
||||
|
||||
sock = serial.connect(virtual_machine, port, getpass.getuser())
|
||||
return sock, streamexpect.wrap(sock, echo=True, close_stream=False)
|
||||
|
||||
|
||||
@ -921,7 +928,9 @@ def stage_install_controller0():
|
||||
|
||||
vboxmanage.vboxmanage_startvm(ctrlr0, V_BOX_OPTIONS.headless)
|
||||
|
||||
sock = serial.connect(ctrlr0, 10000, getpass.getuser())
|
||||
port = 10000 + int(V_BOX_OPTIONS.nat_controller0_local_ssh_port)
|
||||
|
||||
sock = serial.connect(ctrlr0, port, getpass.getuser())
|
||||
cont0_stream = streamexpect.wrap(sock, echo=True, close_stream=False)
|
||||
|
||||
install_controller_0(
|
||||
|
Loading…
x
Reference in New Issue
Block a user