make spawn's query port a configurable parameter