Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env bash
- out=`ssh merlin "ssh athena \"ps U xrylko00\""`
- IFS=$'\n' ### changes break point for arrays!!! no break on spaces
- # master
- masters=("master.py 1"
- "master.py 3"
- "master.py 4")
- for master in ${masters[*]}
- do
- if [[ $out != *$master* ]]
- then
- echo "Starting master.sh ${master:9:2}"
- ssh merlin ssh athena "screen -dmS \"master\" /mnt/minerva1/nlp/projects/spinn3r/master/master.sh ${master:9:2}"
- fi
- done
- # termvector
- if [[ $out != *termvector.sh* ]]
- then
- echo "Starting termvector.sh"
- ssh merlin ssh athena 'screen -dmS "termvector" /mnt/minerva1/nlp/projects/spinn3r/db/termvector.sh'
- fi
- # affected
- if [[ $out != *affected.sh* ]]
- then
- echo Starting affected.sh
- ssh merlin ssh athena 'screen -dmS "affected" /mnt/minerva1/nlp/projects/spinn3r/db/affected.sh'
- fi
- # stahovak
- if [[ $out != *stahovak.sh* ]]
- then
- echo Starting stahovak.sh
- ssh merlin ssh athena 'screen -dmS "stahovak" /mnt/minerva1/nlp/projects/spinn3r/stahovak/stahovak.sh'
- fi
- # alchemized
- if [[ $out != *alchemized.sh* ]]
- then
- echo Starting alchemized.sh
- ssh merlin ssh athena 'screen -dmS "alchemized" /mnt/minerva1/nlp/projects/spinn3r/stahovak/alchemized.sh'
- fi
- # stanfordtoinstances.py
- if [[ $out != *stanfordtoinstances.sh* ]]
- then
- echo Starting stanfordtoinstances.sh
- ssh merlin ssh athena 'screen -dmS "stanfordtoinstances" /mnt/minerva1/nlp/projects/spinn3r/db/stanfordtoinstances.sh'
- fi
- # calaised
- calaiss=(
- "calaised.py 0"
- "calaised.py 100"
- )
- for calais in ${calaiss[*]}
- do
- if [[ $out != *$calais* ]]
- then
- echo "Starting \"calaised.sh ${calais:12:5}\""
- ssh merlin ssh athena "screen -dmS \"calaised\" /mnt/minerva1/nlp/projects/spinn3r/stahovak/calaised.sh ${calais:12:5}"
- fi
- done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement