Source code for gws.server.cli

from argh import arg

import gws
from . import control

COMMAND = 'server'


[docs]@arg('--cfg', help='configuration file') def start(cfg=None): """Create the server start script.""" control.start(cfg)
[docs]def stop(): """Stop the server""" control.stop()
[docs]@arg('--cfg', help='configuration file') def reconfigure(cfg=None): """Reconfigure and gracefully reload the server""" control.reconfigure(cfg)
[docs]@arg('--modules', help='server modules to reload') def reload(modules=None): """Gracefully reload the server without reconfiguring""" control.reload(gws.as_list(modules))
[docs]@arg('--cfg', help='configuration file') def configure(cfg=None): """Configure the server""" control.configure(cfg)