summaryrefslogtreecommitdiff
path: root/redis.sh
diff options
context:
space:
mode:
authorAndreas Maunz <andreas@maunz.de>2011-03-31 10:24:42 +0200
committerAndreas Maunz <andreas@maunz.de>2011-03-31 10:24:42 +0200
commitb63ed2a6443ba77269b5ec4190658c80a027c7ed (patch)
treeb80e9c0db930652ba4aa389dff3e872af1e213de /redis.sh
parente8eb03a9b2489b06e843a44a653fdfa347de80cc (diff)
redis.sh
Diffstat (limited to 'redis.sh')
-rwxr-xr-xredis.sh15
1 files changed, 12 insertions, 3 deletions
diff --git a/redis.sh b/redis.sh
index 5cef1bc..b66fa6f 100755
--- a/redis.sh
+++ b/redis.sh
@@ -44,20 +44,27 @@ if ! $REDIS_DONE; then
echo "Need root password: "
echo "vm.overcommit_memory = 1" | sudo tee -a /etc/sysctl.conf >>$LOG 2>&1
- cd $PREFIX
+ cd /tmp
URI="http://redis.googlecode.com/files/redis-$REDIS_VER.tar.gz"
if ! $WGET -O - "$URI" 2>>$LOG | tar zxv >>$LOG 2>&1; then
printf "%25s%15s\n" "'Download'" "FAIL"
fi
printf "%25s%15s\n" "'Download'" "DONE"
- cd $REDIS_DEST >>$LOG 2>&1
- if ! make>>$LOG 2>&1; then
+ cd redis-$REDIS_VER >>$LOG 2>&1
+ if ! make "PREFIX=$REDIS_DEST" >>$LOG 2>&1; then
printf "%25s%15s\n" "'Make'" "FAIL"
exit 1
fi
printf "%25s%15s\n" "'Make'" "DONE"
+ if ! make install >>$LOG 2>&1; then
+ printf "%25s%15s\n" "'Install'" "FAIL"
+ exit 1
+ fi
+ printf "%25s%15s\n" "'Install'" "DONE"
+
+
if ! grep "daemonize yes" $REDIS_SERVER_CONF >>$LOG 2>&1 ; then
echo "daemonize yes" > $REDIS_SERVER_CONF 2>$LOG
fi
@@ -67,6 +74,8 @@ if ! $REDIS_DONE; then
fi
fi
+cd "$DIR"
+
echo
echo "Preparing Redis..."
if [ ! -f $REDIS_CONF ]; then