From 8cc5b57c5468158096d939a1518e42968ceb47da Mon Sep 17 00:00:00 2001 From: Tom Wiesing Date: Tue, 12 Jul 2022 16:30:06 +0200 Subject: [PATCH] Split into monday_full.sh & monday_short.sh This commit splits the 'monday.sh' script into a shell script 'monday_full.sh' (to update, rebuild, and redo all instances) and 'monday_short.sh' (to rebuild only the core system). This brings the scripts in line with our current policy. --- distillery/{monday.sh => monday_full.sh} | 0 distillery/monday_short.sh | 30 ++++++++++++++++++++++++ 2 files changed, 30 insertions(+) rename distillery/{monday.sh => monday_full.sh} (100%) create mode 100644 distillery/monday_short.sh diff --git a/distillery/monday.sh b/distillery/monday_full.sh similarity index 100% rename from distillery/monday.sh rename to distillery/monday_full.sh diff --git a/distillery/monday_short.sh b/distillery/monday_short.sh new file mode 100644 index 0000000..db9cc04 --- /dev/null +++ b/distillery/monday_short.sh @@ -0,0 +1,30 @@ +#!/bin/bash +set -e + +# read the lib/shared.sh and read the slug argument. +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" +cd "$DIR" +source "$DIR/lib/lib.sh" + +# Read the 'GRAPHDB_ZIP' argument from the command line. +# If it's not set, throw an error. +GRAPHDB_ZIP=$1 +if [ -z "$GRAPHDB_ZIP" ]; then + log_error "Usage: monday_short.sh GRAPHDB_ZIP" + exit 1; +fi; + + +# Backup +log_info " => Running backup, this will take a long time" +bash backup_all.sh + +# system install +log_info " => Reinstalling system" +bash system_install.sh "$GRAPHDB_ZIP" + +# rebuild all the systems +log_info " => Rebuilding all instances" +bash rebuild_all.sh + +log_info " => Done, have a great week"