diff --git a/example-conf.yml b/example-conf.yml index 6b98c7c..aa8e716 100644 --- a/example-conf.yml +++ b/example-conf.yml @@ -477,6 +477,10 @@ relay: # False. allow_clientbot_pms: false + # Sets the suffix that relay subservers should use. Defaults to "relay" (as in net1.relay, + # net2.relay, etc.) if not specified. + #server_suffix: "relay.yournet.net" + games: # Sets the nick of the Games service, if you're using it. This defaults to "games" if not defined. nick: Games diff --git a/plugins/relay.py b/plugins/relay.py index 6174f25..5483730 100644 --- a/plugins/relay.py +++ b/plugins/relay.py @@ -252,7 +252,10 @@ def spawnRelayServer(irc, remoteirc): try: # ENDBURST is delayed by 3 secs on supported IRCds to prevent # triggering join-flood protection and the like. - sid = irc.proto.spawnServer('%s.relay' % remoteirc.name, + suffix = conf.conf.get('relay', {}).get('server_suffix', 'relay') + # Strip any leading or trailing .'s + suffix = suffix.strip('.') + sid = irc.proto.spawnServer('%s.%s' % (remoteirc.name, suffix), desc="PyLink Relay network - %s" % (remoteirc.serverdata.get('netname')\ or remoteirc.name), endburst_delay=3)