I was using a log watcher that could run a command on a regex match, but I remember having an elaborate .htaccess that would shell out all kinds of things... many ways to tie them together, all very hacky.
it might not even be that hacky to be honest. in some ways modern log aggregation isn’t that different, just insulated by more steps and safe guards. less moos though.
Years ago I had /var/www/lights_on.sh that turned lights on in my room. Only hardened against RCE by Wi-Fi password, but was possible. It broke later. The real problem was that browsers sometimes prefetched it.