From 6514dfb5482368123b7a61b7fa778cdc71283661 Mon Sep 17 00:00:00 2001 From: Felix Richter Date: Sat, 14 May 2011 22:45:58 +0200 Subject: updated debian build script to behave correctly in the current context --- retiolum/hosts/.scripts/build_debian.sh | 26 +++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) (limited to 'retiolum') diff --git a/retiolum/hosts/.scripts/build_debian.sh b/retiolum/hosts/.scripts/build_debian.sh index d8fcec2f..ddc63aed 100755 --- a/retiolum/hosts/.scripts/build_debian.sh +++ b/retiolum/hosts/.scripts/build_debian.sh @@ -1,16 +1,28 @@ #!/bin/bash set -x -MYIP=10.0.7.7.55 +if [ ! "$MYIP" ] +then + MYIP=10.0.7.7.55 +fi +if [ ! "$MYHOSTNAME" ] +then + MYHOSTNAME="penis" +fi +if [ "$MYHOSTNAME" = "penis" ]; +then + read -n1 -p "name is penis, are u sure? [yN]" + if [[ "$REPLY" != [yY] ]] + then + echo "then better RTFC" + echo "bailing out" + exit 0 + fi +fi apt-get install tinc git curl python -git clone https://github.com/makefu/shack-retiolum.git +./install.sh "$MYHOSTNAME" "$MYIP" -cd shack-retiolum - -./install.sh `hostname` $MYIP -cd .. -rm shack-retiolum # for autostart sed -i '/retiolum/d' /etc/tinc/nets.boot echo "retiolum" >> /etc/tinc/nets.boot -- cgit v1.2.3