summaryrefslogtreecommitdiffhomepage
path: root/bazarr.py
diff options
context:
space:
mode:
Diffstat (limited to 'bazarr.py')
-rw-r--r--bazarr.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/bazarr.py b/bazarr.py
index 3a90e25c4..ed3595a91 100644
--- a/bazarr.py
+++ b/bazarr.py
@@ -5,6 +5,8 @@ gc.enable()
from get_argv import config_dir, no_update
+from daemon import shutdown_bazarr, restart_bazarr
+
import os
import sys
reload(sys)
@@ -187,6 +189,14 @@ def redirect_root():
authorize()
redirect (base_url)
+@route(base_url + 'shutdown')
+def shutdown():
+ shutdown_bazarr(False)
+
+@route(base_url + 'restart')
+def restart():
+ restart_bazarr()
+
@route(base_url + 'static/:path#.+#', name='static')
@custom_auth_basic(check_credentials)
def static(path):