This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch release/0.0.3.x in repository x2gobroker. commit 16c5590d34e6b33508ea4b9976485990efbc1cda Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Date: Sun Sep 24 18:08:27 2017 +0200 Make hostname detection work for the default configuration (that defines localhost session profiles). --- x2gobroker/brokers/base_broker.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/x2gobroker/brokers/base_broker.py b/x2gobroker/brokers/base_broker.py index 2c6bbc2..938270e 100644 --- a/x2gobroker/brokers/base_broker.py +++ b/x2gobroker/brokers/base_broker.py @@ -27,6 +27,7 @@ __NAME__ = 'x2gobroker-pylib' # modules import types import copy +import socket import uuid import netaddr import random @@ -1355,6 +1356,14 @@ class X2GoBroker(object): while not selected_session and server_list: + # X2Go Server uses the system's hostname, so let's replace + # that here automatically, if we tested things via localhost... + for h in server_list: + if h == 'localhost': + server_list.remove(h) + server_list.append(socket.gethostname()) + + matching_server_names = None if session_list: matching_server_names = x2gobroker.utils.matching_hostnames(server_list, [ si.split('|')[3] for si in session_list ]) -- Alioth's /srv/git/code.x2go.org/x2gobroker.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/x2gobroker.git