Skip to content

Instantly share code, notes, and snippets.

@snevas
Created February 18, 2023 15:42
Show Gist options
  • Save snevas/8f3364293c7d8a5008ff99f485e9a27e to your computer and use it in GitHub Desktop.
Save snevas/8f3364293c7d8a5008ff99f485e9a27e to your computer and use it in GitHub Desktop.
UDR led blinker on doorbell ring
[Unit]
Description=LEDs on doorbell ring
After=unifi-protect.service
#Install tmux and multitail from apt
#Replace sleep with aplay on UDM if you want it to play sound
[Service]
ExecStart=tmux new-session -d -s multitail multitail -D -ex "EventRingButtonPressed" "uled-ctrl blink 500 008000 FF0000 && sleep 10 && uled-ctrl fw idle" -iw "/ssd1/.data/unifi-protect/logs/cameras/*.log" 30
ExecStop=tmux kill-session -t multitail
User=root
Type=forking
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment