flow to shut down a Raspberry Pi

This enables you to cleanly shutdown a Raspberry Pi without having to ssh in to run sudo poweroff. Use with some care, as it gives anyone with access to the Node-RED GUI the ability to shut the machine down!

[{"id":"ab01bcd1.c410e","type":"inject","name":"shutdown!","topic":"","payload":"","repeat":"","crontab":"","once":false,"x":493,"y":479,"z":"a7da7b08.56417","wires":[["8f9f1fe.3f891e"]]},{"id":"8f9f1fe.3f891e","type":"exec","command":"sudo poweroff #","append":"","useSpawn":"","name":"turn off Pi","x":667,"y":478,"z":"a7da7b08.56417","wires":[[],[],[]]}]

Flow Info

Created 11 years ago
Updated 9 years, 4 months ago
Rating: not yet rated

Owner

Actions

Rate:

Node Types

Core
  • exec (x1)
  • inject (x1)

Tags

  • Raspberry
  • Pi
  • shutdown
  • sudo
  • administrator
Copy this flow JSON to your clipboard and then import into Node-RED using the Import From > Clipboard (Ctrl-I) menu option