I have ubuntu server with crontab that is supposed to run mkdocs in tmux at reboot.
Worth noting is that I configure crontab by going into crontab -e.
Line is:
@reboot /usr/bin/tmux new-session -d -s "MKDOCS" "cd /root/mkdocs && mkdocs serve -a 192.168.0.10:8080"
However, nothing happens.
I have tried just /usr/bin/tmux new-session -d -s "MKDOCS" "cd /root/mkdocs && mkdocs serve -a 192.168.0.10:8080" and it runs fine.
What can be the reason? Thanks
$PATHused by cron. - On a different note: most sysadmins prefer services that actually run as a service rather than in tmux/screen session. – Bob Jan 10 '22 at 12:57