Created
January 11, 2022 01:58
-
-
Save yanfeng42/0753dd7550fafa5bb723c3cd26dcba29 to your computer and use it in GitHub Desktop.
shell code for bot pomodoro
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# step3.1 | |
# check timedatectl | |
timedatectl | |
# change server timezone | |
sudo timedatectl set-timezone $timezone_you_need | |
# step3.2 | |
# edit crontab to a new timer task | |
crontab -e | |
# add to crontab end. | |
0,25,30,55 * * * * $path_to_fab -f $path_to_fabfile bot_p > $path_to_log 2>&1 | |
# step3.3 | |
# run everty time, just for debug. | |
# * * * * * $path_to_fab -f $path_to_fabfile bot_p > $path_to_log 2>&1 | |
# see task log | |
tail $path_to_log | |
# check cmd was real executed. | |
grep CRON /var/log/syslog |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment