summaryrefslogtreecommitdiffstats
path: root/satellit_installer/satellit_installer
diff options
context:
space:
mode:
authorChristian Rößler2015-02-26 14:02:56 +0100
committerChristian Rößler2015-02-26 14:02:56 +0100
commitce30eff3159a773679c3aca12a58d5a62220119d (patch)
tree3ea4e9f1bd98802ab4fb2a69d01dbd5f8f634ff4 /satellit_installer/satellit_installer
parent[SSPS] firstrun_script.sh: rmdir-ing /root/installer9 (diff)
downloadsetup-scripts-ce30eff3159a773679c3aca12a58d5a62220119d.tar.gz
setup-scripts-ce30eff3159a773679c3aca12a58d5a62220119d.tar.xz
setup-scripts-ce30eff3159a773679c3aca12a58d5a62220119d.zip
[SSPS] Several more preparations for version numbers [TO BE DEBUGGED!]
Diffstat (limited to 'satellit_installer/satellit_installer')
-rwxr-xr-xsatellit_installer/satellit_installer28
1 files changed, 18 insertions, 10 deletions
diff --git a/satellit_installer/satellit_installer b/satellit_installer/satellit_installer
index 1fd0eee..2ca8080 100755
--- a/satellit_installer/satellit_installer
+++ b/satellit_installer/satellit_installer
@@ -24,13 +24,23 @@ echo "#"
echo "# bwSuite Server and environment autoinstaller"
echo "#"
-if [ "$1" == "-h" -o "$1" == "--help" ]; then
- echo "#"
- echo "# Currently there are no options to be set. If you need to change"
- echo "# any predefined values, take a look into includes/00-variables.inc"
- echo "# and set them there."
- exit
-fi
+case "$1" in
+ "-h" | "--help")
+ echo "#"
+ echo "# Currently there is just a version string to be given via -V or --version."
+ echo "# If you need to change any predefined values, take a look into includes/00-variables.inc."
+ echo "# and set them there."
+ exit
+ ;;
+ "-V" | "--version")
+ [ -z "$2" ] && { echo "No version string has been given - exit."; exit 1; }
+ export VERSION="$2"
+ ;;
+ *) echo "# Restarting with --help ..."
+ exec $(readlink -f "$0 --help")
+ exit 0 # Never reached, but one for the aesthetics!
+ ;;
+esac
# Set and save some environmental variables:
OLDUMASK=$(umask)
@@ -41,10 +51,8 @@ export SELF="$(readlink -f "$0")"
export BASEDIR="$(dirname "${SELF}")"
#
-#
# TRAPPING hierhin!
#
-#
# First, to include includes include them:
echo -n "# Sourcing includes: "
@@ -56,7 +64,7 @@ echo " ok"
####### Main program #######
-apt-get update # No harm done even if not necessary
+system_upgrade # No harm done even if not necessary
install_packages "$PACKAGELIST_SCRIPT" # Packages needed for script