summaryrefslogtreecommitdiffhomepage
path: root/bazarr.py
diff options
context:
space:
mode:
authormorpheus65535 <[email protected]>2018-10-02 22:31:20 -0400
committermorpheus65535 <[email protected]>2018-10-02 22:31:20 -0400
commitcb385d870639c2fdd2db54d97dca65b92df410d7 (patch)
treea0d641778ca23d32a0595d106e412baf030ba9ce /bazarr.py
parent7c70564646bbaa2b6f3ac22208203de4e8d1f6e2 (diff)
downloadbazarr-cb385d870639c2fdd2db54d97dca65b92df410d7.tar.gz
bazarr-cb385d870639c2fdd2db54d97dca65b92df410d7.zip
Initial commit
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):