[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r15332 - gauger
From: |
gnunet |
Subject: |
[GNUnet-SVN] r15332 - gauger |
Date: |
Fri, 27 May 2011 14:22:46 +0200 |
Author: bartpolot
Date: 2011-05-27 14:22:46 +0200 (Fri, 27 May 2011)
New Revision: 15332
Modified:
gauger/install.sh
Log:
Improved installation process
Modified: gauger/install.sh
===================================================================
--- gauger/install.sh 2011-05-27 11:22:19 UTC (rev 15331)
+++ gauger/install.sh 2011-05-27 12:22:46 UTC (rev 15332)
@@ -17,6 +17,7 @@
echo "gauger system-wide."
echo ""
echo "WARNING: default paths probably will *NOT* work, please change them."
+ echo ""
fi
@@ -165,12 +166,55 @@
AllowOverride Limit FileInfo
</Directory>
EOF
+
+ echo "Please input route where to store gaugers data files"
+ echo " default [/var/lib/gauger]"
+ read VARPATH
+ if [ "$VARPATH" = "" ]; then
+ VARPATH="/var/lib/gauger"
+ fi
+ if [ ! -d "$VARPATH" ]; then
+ mkdir -p "$VARPATH"
+ fi
+
+ echo "Please input a string tu use as password hash salt"
+ echo " default [15 bit random number]"
+ read SALT
+ if [ "$SALT" = "" ]; then
+ SALT="$RANDOM"
+ fi
+
+ echo "Do you want to turn on the auto add feature?"
+ echo "With audo add hosts not previously known are added"
+ echo "automatically to the configuration file the first time"
+ echo "they log data to the gauger server [y/N]"
+ read AUTOADD
+ if [[ "$AUTOADD" = "y" || "$AUTOADD" = "Y" ]]; then
+ AUTOADD="1"
+ else
+ AUTOADD="0"
+ fi
+
+ echo "Please input an initial username"
+ read USERNAME
+ if [ "$USERNAME" != "" ]; then
+ echo "Please input a password for $USERNAME"
+ read PASSWORD
+ PASSWORD=`echo "$PASSWORD$SALT" | sha1sum`
+ PASSWORD=${PASSWORD%% *}
+ else
+ USERNAME="#username"
+ PASSWORD="\"salted sha1 hash of the password\""
+ fi
+
cat > "$CONFIGPATH/gauger.conf" <<EOF
-[dir]
-/var/lib/gauger
+[config]
+data = "$VARPATH"
+salt = "$SALT"
+auto_add = "$AUTOADD"
[hosts]
-#user,password=hostname
+$USERNAME=$PASSWORD
EOF
ln -s "$CONFIGPATH/apache.conf" "$APACHEPATH/gauger"
cp "$CONFIGPATH/gauger.conf" "$SERVERPATH/"
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r15332 - gauger,
gnunet <=