Fellow EOS friends, I’d like to pick you brains, the challenge at hand is a few webcams which load their pictures onto my Arch server whenever they record an alarm.
I right now completed a little script which monitors (inotifywait) the camera folder and puts out a clickable link on the console
$ scripts/monitorCameras.sh
Camera tracker v. 1.0
Stairs 21:14 -> smb://camera@homeserver/Cameras/10_18_126_147/000/093
This works, but, I need to ssh into the server to run the script and see the output.
What I really want is some sort of notification on my laptop. My DE is Plasma so I wonder if I somehow can push these alerts as a KDE notification?
Not an issue of speed reading but rather brain reading
I was about to add kdeconnect to my opening post but then kept it more generic. Somehow it must have transmitted over…or maybe you read my response in the kdeconnect thread
Indeed, this may do the trick without any 3rd party, I noticed a “host” parameter.
Edit: No, the host parameter is for XMPP only. Maybe I’ll have the server write into a file which I monitor from my laptop, I could use notify-send “test”…but these notifications aren’t clickable…
I am now considering a script local to the laptop which will go over the network and monitor the server file for changes and which will show the link in the KDE panel via the “Command-Output” Plasma applet.
Thanks guys, good food for thought. I’ll report back once I got something.
Edit: Making progress, I am now running my server script directly via ssh which allows me to securely pull the screen output over to my laptop without the need to copy log files or monitor files across the network:
ssh homeserver ~/scripts/monitorCameras.sh | tee ssh-session.log
From the local ssh-session.log file I can push things as notification:
x=$(tail -1 ssh-session.log); notify-send $x
The only thing I haven’t figured out yet is how to make the notify-send message clickable
Edit2: Got a working solution
I am now using ssh as shown above as Systemd daemon, the output of the script goes into a temporary log file which I monitor with the CommandOutput Applet. When I click on the string I launch the jpg via xdg-open…
Boy, I really love Linux for solutions like this…no programing, no bending over backwards, but rather linking together existing tools and capabilities.