Improve ycdl_flask_dev helptext.
This commit is contained in:
parent
ad306ae771
commit
d5b50ff1f6
1 changed files with 25 additions and 4 deletions
|
@ -1,8 +1,29 @@
|
||||||
'''
|
'''
|
||||||
|
ycdl_flask_dev
|
||||||
|
==============
|
||||||
|
|
||||||
This file is the gevent launcher for local / development use.
|
This file is the gevent launcher for local / development use.
|
||||||
|
|
||||||
Simply run it on the command line:
|
> ycdl_flask_dev port <flags>
|
||||||
python ycdl_flask_dev.py [port]
|
|
||||||
|
port:
|
||||||
|
Port number on which to run the server. Default 5000.
|
||||||
|
|
||||||
|
--dont-create:
|
||||||
|
If this flag is passed, YCDL will raise an error if there is not an
|
||||||
|
existing ycdl.db in the current directory.
|
||||||
|
|
||||||
|
--https:
|
||||||
|
If this flag is not passed, HTTPS will automatically be enabled if the port
|
||||||
|
is 443. You can pass this flag to enable HTTPS on other ports.
|
||||||
|
We expect to find ycdl.key and ycdl.crt in frontends/ycdl_flask/https.
|
||||||
|
|
||||||
|
--localhost-only:
|
||||||
|
If this flag is passed, only localhost will be able to access the server.
|
||||||
|
Other users on the LAN will be blocked.
|
||||||
|
|
||||||
|
--refresh-rate X:
|
||||||
|
Starts a background thread that refreshes all channels once every X seconds.
|
||||||
'''
|
'''
|
||||||
import gevent.monkey; gevent.monkey.patch_all()
|
import gevent.monkey; gevent.monkey.patch_all()
|
||||||
|
|
||||||
|
@ -11,6 +32,7 @@ import gevent.pywsgi
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
|
from voussoirkit import betterhelp
|
||||||
from voussoirkit import operatornotify
|
from voussoirkit import operatornotify
|
||||||
from voussoirkit import pathclass
|
from voussoirkit import pathclass
|
||||||
from voussoirkit import vlogging
|
from voussoirkit import vlogging
|
||||||
|
@ -97,8 +119,7 @@ def main(argv):
|
||||||
parser.add_argument('--refresh_rate', '--refresh-rate', dest='refresh_rate', type=int, default=None)
|
parser.add_argument('--refresh_rate', '--refresh-rate', dest='refresh_rate', type=int, default=None)
|
||||||
parser.set_defaults(func=ycdl_flask_launch_argparse)
|
parser.set_defaults(func=ycdl_flask_launch_argparse)
|
||||||
|
|
||||||
args = parser.parse_args(argv)
|
return betterhelp.single_main(argv, parser, __doc__)
|
||||||
return args.func(args)
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
raise SystemExit(main(sys.argv[1:]))
|
raise SystemExit(main(sys.argv[1:]))
|
||||||
|
|
Loading…
Reference in a new issue