agri_xumu/cron_update.sh

8 lines
209 B
Bash
Raw Normal View History

2024-02-27 09:46:34 +08:00
#!/bin/bash
set -e
sudo crontab -r
sudo crontab -l > cron.cron
2024-02-27 09:49:08 +08:00
echo "0 */1 * * * sudo systemctl restart supervisor" >> cron.cron
2024-02-27 09:46:34 +08:00
sudo crontab cron.cron
sudo systemctl restart cron.service
sudo rm -rf cron.cron