I'm running a script (in a Laravel project) that takes a few hours to complete. nohup to prevent it from exiting if my ssh session is disconnected.
nohup php artisan do:thing 2>&1 | tee ~/tmp It starts off nicely, but after some time, I get a broken pipe error and it stops outputing things, and tee stops as well - the doc stops at that point.
I guess it's because the tee process got killed by the ssh session drop? Can I prevent it?
Could I maybe disown the tee process and prevent ssh from terminating it?