knro / indiwebmanager

Web Manager for INDI Server
http://www.indilib.org
GNU Lesser General Public License v2.1
43 stars 32 forks source link

Add Reboot and Poweroff commands #39

Closed Chris-Rowland closed 4 years ago

Chris-Rowland commented 4 years ago

This seems to work but I'm pretty unfamiliar with python, javascript and web design so it will be worth looking at what I've done carefully, particularly the additional buttons in indi.tpl

One thing may be the version of python, I think I used python 3 but indi.conf mentions 2.7.

Strange how little security there is for reboot and poweroff, at least on my system. I did allow make through sudo for ease of development but thought it wouldn't affect other commands.

Thanks for your help, the only issue was that call("systemctl reboot") failed but call("reboot") worked.

Chris

Chris-Rowland commented 4 years ago

CI things now fixed - hopefully!

Chris-Rowland commented 4 years ago

I've made the change as requested, I'd but this in more as a bread crumb.