Last active
August 29, 2015 14:11
-
-
Save voidman/efaff631760835db2132 to your computer and use it in GitHub Desktop.
Restart supervisor job
This file contains 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
function jobrestart() | |
{ | |
if [ "$1" = "" ]; then | |
echo "请输入任务名称" | |
return | |
fi | |
sudo supervisorctl -c /data/code/supervisord.conf status | grep $1 | awk '{print $1 }' | xargs sudo supervisorctl -c /data/code/supervisord.conf restart | |
} | |
用法: | |
jobrestart your_job_name |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment