diff options
author | Determinant <ted.sybil@gmail.com> | 2014-12-29 00:34:16 +0800 |
---|---|---|
committer | Determinant <ted.sybil@gmail.com> | 2014-12-29 00:34:16 +0800 |
commit | 4c7c9dcdfd05a2d9648756c0da5c68588929ba5d (patch) | |
tree | 2c1681ad60e1469b4dda7a2ab6a0d03637dbde1e /monitor_daemon.sh | |
parent | 5dc3a3b043a990fc58a4ead74c2c5c92e910727d (diff) |
restructured the project
Diffstat (limited to 'monitor_daemon.sh')
-rwxr-xr-x | monitor_daemon.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/monitor_daemon.sh b/monitor_daemon.sh index fed2967..7d976ee 100755 --- a/monitor_daemon.sh +++ b/monitor_daemon.sh @@ -4,18 +4,18 @@ # echo "you must specify the triggered command" # exit 1 #fi +CLIENT="python lab_monitor_client.py" function on_exit { - python client.py --drop "$JID" + $CLIENT --drop "$JID" exit 0 } -JID=$(python client.py --create "$JMNAME" --type "$JTYPE") +JID=$($CLIENT --create "$JMNAME" --type "$JTYPE") if [[ "$JID" == "" ]]; then echo "failed to create monitor" exit 1 fi trap on_exit SIGINT SIGTERM -CLIENT="python client.py" while [ 1 ]; do trigger sleep 1 |