Commit 51a63819 authored by Gero Müller's avatar Gero Müller
Browse files

add port parameter to vispad

parent cf7bc522
......@@ -209,6 +209,9 @@ def parse_commandline():
help='Directory containing server '\
'data and cache files (default: %s)'
% os.path.join(default_base, "conf"))
parser.add_argument('-p', '--port',
default=None,
help='which port the server shall listen on')
parser.add_argument('-l', '--loglevel', dest='loglevel', default=None,
help='enable debug messages')
parser.add_argument('--no-daemon', dest='daemon', action='store_const',
......
......@@ -302,6 +302,9 @@ class Server(object):
if os.path.isfile(cherrypy_conf):
cherrypy.config.update(cherrypy_conf)
if args.port:
cherrypy.config.update({'server.socket_port': int(args.port)})
from vispa.controller.root import RootController
self.controller = RootController()
self._load_extensions()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment