crontab does not execute script or command containing tmux or screen?
I want cron to execute a script at a certain time which sends a command to a detached tmux/screen session.
I have already started a session with "tmux new -d -n stuffn -s stuffs "blah" OR screen -dmS stuffs blah.
I then put "tmux send -t stuffs:stuffn "blah" C-m OR screen -x stuffs -X stuff "blah" in a script to send command to detached session. I ran the script manually it worked but when put in cron nothing happens. The cron script looks like "46 17 * * * /bin/sh /location/script.sh".
Putting the command directly in cron also doesnt do anything. I am sure cron is working itself.
Does anyone have an idea of whats going on?
Thanks in advance!