#!/bin/sh # Kill any process leftover from previous run kill $(ps aux | grep "[p]ython -m CGIHTTPServer 8080" | awk '{print $2}') kill $(ps aux | grep "[p]ython deploy/unifiedlogger.zip" | awk '{print $2}') # Get path to this script # $0 contains path to the script file, even if launched from file manager SCRIPT_PATH=$(dirname "$(readlink -f "$0")") # CD to the script folder cd "$SCRIPT_PATH" # Start the Simulator System with the full incident script cd ../webapps # Delete any existing CADcomments.log rm dynamicdata/CADcomments.log # start the local webserver echo "Starting webserver in folder" `pwd` python -m CGIHTTPServer 8080 & sleep 1 cd .. java -DCONFIG_DIR=config/devlinux -jar deploy/CADserver.jar & sleep 5 # Start Unified Logger Service python deploy/unifiedlogger.zip config/devlinux & sleep 5 java -jar deploy/SimManager.jar full_script_2016.xml & sleep 10 # Start a browser and run the web applications firefox localhost:8080/einotebook localhost:8080/cptms localhost:8080/unifiedlogmonitor.html & sleep 10 java -DCONFIG_DIR=config/devlinux -jar deploy/CADclient.jar & sleep 5