From e6ae98c96ba7d47c1d882b1778c74af25343ced4 Mon Sep 17 00:00:00 2001 From: Dale Henrichs Date: Wed, 23 Oct 2019 12:17:59 -0700 Subject: [PATCH] Issue #260: initial version of bootstrap.sh script ... make sure GemStone 3.5.0 product tree present and download zipped gsdevkit_launcher solo extent [ci skip] --- alt_bin/bootstrap.sh | 44 +++++++++++++++++++ shared/repos/GsDevKit_launcher/README.md | 3 ++ ...uild_SystemUser_gsdevkit_launcher_deployer | 2 + 3 files changed, 49 insertions(+) create mode 100755 alt_bin/bootstrap.sh diff --git a/alt_bin/bootstrap.sh b/alt_bin/bootstrap.sh new file mode 100755 index 00000000..a6708434 --- /dev/null +++ b/alt_bin/bootstrap.sh @@ -0,0 +1,44 @@ +#! /usr/bin/env bash +#========================================================================= +# Copyright (c) 2019 GemTalk Systems, LLC . +# +# MIT license: https://github.com/GsDevKit/GsDevKit_home/blob/master/license.txt +#========================================================================= + +theArgs="$*" +source "${GS_HOME}/bin/private/shFeedback" +start_banner + +# +# This script does the dirty work needed to get to the point where +# gsdevkit_launcher scripts can be run + +set -x # so we can see what is going on + +gsdevkit_launcher_version="v0.10.0" + +cd $GS_HOME/shared/gemstone + +# make sure 3.5.0 is installed and create symbolic link to the 3.5.0 product tree +$GS_HOME/bin/downloadGemStone 3.5.0 +if [ ! -d "$GS_HOME/shared/downloads/products/GemStone64Bit3.5.0-x86_64.Linux" ] ; then + # not Linux + if [ ! -d "$GS_HOME/shared/downloads/products/GemStone64Bit3.5.0-i386.Darwin" ] ; then + # not Mac + exit_1_banner "gsdevkit_launcher currently supported only on Mac or Linux platforms" + else + ln -s $GS_HOME/shared/downloads/products/GemStone64Bit3.5.0-i386.Darwin product + fi +else + ln -s $GS_HOME/shared/downloads/products/GemStone64Bit3.5.0-x86_64.Linux product +fi + +# download and install the gsdevkit_launcher solo extent +pushd snapshots + curl -L -O -s -S "https://github.com/dalehenrich/st_launcher/releases/download/$gsdevkit_launcher_version/extent0.gsdevkit_launcher.dbf.zip" + rm -rf extent0.gsdevkit_launcher.dbf + unzip -q extent0.gsdevkit_launcher.dbf.zip +popd + +# End of script +exit_0_banner "...finished" diff --git a/shared/repos/GsDevKit_launcher/README.md b/shared/repos/GsDevKit_launcher/README.md index c4634666..43de9573 100644 --- a/shared/repos/GsDevKit_launcher/README.md +++ b/shared/repos/GsDevKit_launcher/README.md @@ -30,6 +30,9 @@ cd $GS_HOME git fetch --all git checkout issue_260 +# bootstrap gsdevkit_launcher script support +$GS_HOME/alt_bin/bootstrap.sh + # add alt_bin and alt_bin/examples to your path . alt_bin/defHome_PATH.env diff --git a/shared/repos/GsDevKit_launcher/bootstrapping/gemstone/gsdevkit_home/newBuild_SystemUser_gsdevkit_launcher_deployer b/shared/repos/GsDevKit_launcher/bootstrapping/gemstone/gsdevkit_home/newBuild_SystemUser_gsdevkit_launcher_deployer index 4f974d98..20d6249c 100755 --- a/shared/repos/GsDevKit_launcher/bootstrapping/gemstone/gsdevkit_home/newBuild_SystemUser_gsdevkit_launcher_deployer +++ b/shared/repos/GsDevKit_launcher/bootstrapping/gemstone/gsdevkit_home/newBuild_SystemUser_gsdevkit_launcher_deployer @@ -15,6 +15,8 @@ cp extents/extent0.dbf snapshots/extent0.gsdevkit_launcher.dbf # cp the solo extent to snapshots directory chmod oug-w snapshots/extent0.gsdevkit_launcher.dbf cp -f snapshots/extent0.gsdevkit_launcher.dbf $GS_HOME/shared/gemstone/snapshots/ +rm -rf $GS_HOME/shared/gemstone/snapshots/extent0.gsdevkit_launcher.dbf.zip +zip $GS_HOME/shared/gemstone/snapshots/extent0.gsdevkit_launcher.dbf.zip snapshots/extent0.gsdevkit_launcher.dbf startStone $GEMSTONE_NAME # in 3.5.1 snapshot up above