summaryrefslogtreecommitdiff
path: root/docs/lab/serve.py
diff options
context:
space:
mode:
Diffstat (limited to 'docs/lab/serve.py')
-rwxr-xr-xdocs/lab/serve.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/docs/lab/serve.py b/docs/lab/serve.py
index 91fc12cb0..e0dddebdf 100755
--- a/docs/lab/serve.py
+++ b/docs/lab/serve.py
@@ -31,6 +31,13 @@ except OSError:
addr = ("localhost", 3003)
+if len(sys.argv) > 1:
+ if sys.argv[1] == '-h':
+ print('usage: %s [-h | --bind-any]' % sys.argv[0], file=sys.stdout)
+ sys.exit(0)
+ elif sys.argv[1] == '--bind-any':
+ addr = ("0.0.0.0", 3003)
+
# make ^C instantly exit program
signal.signal(signal.SIGINT, sighandler)