Deploy lite version
[anna.git] / example / diameter / launcher / resources_lite / operation.sh
1 #!/bin/bash
2
3 # General
4 EXE=./ADL-launcher
5
6 _exit () {
7   echo
8   echo $1
9   echo
10   exit 1
11 }
12
13 echo
14 echo
15 [[ "$1" = "" ]] && _exit "Use: $0 <operation string>; i.e.: $0 help"
16
17 PID=$(pgrep `basename $EXE`)
18 [[ $? -ne 0 ]] && _exit "Can't found the process '$EXE'. Use './run.sh' to start it."
19
20 # Send operation:
21 echo $1 > sigusr2.tasks.input
22 kill -s SIGUSR2 $PID
23
24 sleep 1
25 echo
26 echo
27 echo "You could see results on './sigusr2.tasks.output' file."
28 echo
29 echo
30