commit 9b7bb37177398cae933d76568f480affd5964e3b Author: Runa A. Sandvik runa.sandvik@gmail.com Date: Fri Nov 4 07:39:26 2011 +0000
Make sure we can launch private bridges and relays as well. Solves #4350. --- build.sh | 3 +++ rc.local | 2 +- 2 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/build.sh b/build.sh index 1dd5c6c..249fba3 100755 --- a/build.sh +++ b/build.sh @@ -92,6 +92,9 @@ ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -i ${sshkey} ub # this is our startup file that loads tor-prep.sh on first boot ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -i ${sshkey} ubuntu@${host} -q -v -t "sudo wget https://gitweb.torproject.org/tor-cloud.git/blob_plain/HEAD:/rc.local -O /mnt/src/etc/rc.local"
+# Update the rc.local file with the type of relay we want to create (bridge, private-bridge or relay) +ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -i ${sshkey} ubuntu@${host} -q -v -t "sudo sed -i s/type/$1/ /mnt/src/etc/rc.local" + # this script is responsible for installation and configuration of the Tor application ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -i ${sshkey} ubuntu@${host} -q -v -t "sudo wget https://gitweb.torproject.org/tor-cloud.git/blob_plain/HEAD:/ec2-prep.sh -O /mnt/src/etc/ec2-prep.sh"
diff --git a/rc.local b/rc.local index 79586b3..a2af486 100644 --- a/rc.local +++ b/rc.local @@ -1,4 +1,4 @@ #!/bin/sh -e sudo aptitude -y safe-upgrade -sudo /etc/ec2-prep.sh bridge +sudo /etc/ec2-prep.sh type exit 0