root/honeyclient/tags/exp/PRE-kindlund-simpler_agent/bin/bootstrap_agent.sh

Revision 1311, 1.0 kB (checked in by kindlund, 9 months ago)

Marked specific commands as optional.

  • Property svn:executable set to *
  • Property svn:keywords set to Id "$file"
Line 
1 #!/bin/bash
2
3 # $Id$
4
5 echo "Starting up Agent - (Hit CTRL-C multiple times to exit.)"
6
7 # Remove all old /tmp/* entries.
8 rm /tmp/* > /dev/null 2>&1
9
10 # Determine the IP address of the VM running.
11 IP=$(/cygdrive/c/Program\ Files/VMware/VMware\ Tools/VMip.exe -get)
12 echo "IP = $IP"
13
14 # Wait until the VM has a valid IP address.
15 while [ $IP = "0.0.0.0" ] ; do
16     /cygdrive/c/Program\ Files/VMware/VMware\ Tools/VMip.exe -release
17     /cygdrive/c/Program\ Files/VMware/VMware\ Tools/VMip.exe -renew
18     IP=$(/cygdrive/c/Program\ Files/VMware/VMware\ Tools/VMip.exe -get)
19     echo "IP = $IP"
20     sleep 1
21 done
22
23 # Ping a remote site, to test for connectivity (optional).
24 /cygdrive/c/windows/system32/ping.exe pingu.honeyclient.org
25
26 # Change to the honeyclient directory.
27 cd ~/honeyclient
28
29 # Perform an SVN update (optional).
30 svn update
31
32 # Start up the realtime integrity checker.
33 ~/honeyclient/thirdparty/capture-mod/CaptureBAT.exe -c -l "C:\cygwin\tmp\realtime-changes.txt"&
34
35 # Start the Agent code.
36 while [ true ] ; do
37     perl -Ilib bin/StartAgent.pl && sleep 1
38 done
Note: See TracBrowser for help on using the browser.