Loading openflexure_microscope/api/v2/views/actions/system.py +2 −2 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ class ShutdownAPI(View): """ Attempt to shutdown the device """ subprocess.Popen(["shutdown", "-h", "now"]) subprocess.Popen(["sudo", "shutdown", "-h", "now"]) return "{}", 201 Loading @@ -41,6 +41,6 @@ class RebootAPI(View): """ Attempt to reboot the device """ subprocess.Popen(["systemctl", "reboot", "-i"]) subprocess.Popen(["sudo", "shutdown", "-r", "now"]) return "{}", 201 Loading
openflexure_microscope/api/v2/views/actions/system.py +2 −2 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ class ShutdownAPI(View): """ Attempt to shutdown the device """ subprocess.Popen(["shutdown", "-h", "now"]) subprocess.Popen(["sudo", "shutdown", "-h", "now"]) return "{}", 201 Loading @@ -41,6 +41,6 @@ class RebootAPI(View): """ Attempt to reboot the device """ subprocess.Popen(["systemctl", "reboot", "-i"]) subprocess.Popen(["sudo", "shutdown", "-r", "now"]) return "{}", 201