The wizard for Octoprint has a section asking for server commands. Fill in these commands for the entries:
Restart octoprint: sudo systemctl restart octoprint.service Reboot: sudo reboot Shutdown: sudo shutdown -h now