taler-deployment

Deployment scripts and configuration files
Log | Files | Refs | README

commit 8917409c4fbd5ec311e52b349872233e23b70ab6
parent 308225aff3ab06f979fa4eeb11cbeee21840b22b
Author: Marcello Stanisci <stanisci.m@gmail.com>
Date:   Mon, 25 Mar 2019 14:43:29 +0100

More automation for demo/test deployment.

Diffstat:
Mbootstrap-bluegreen | 7++++---
Ademo.sh | 14++++++++++++++
Atest.sh | 14++++++++++++++
3 files changed, 32 insertions(+), 3 deletions(-)

diff --git a/bootstrap-bluegreen b/bootstrap-bluegreen @@ -12,9 +12,9 @@ # demo-blue$ ~/deployment/bootstrap-bluegreen demo # demo-green$ ~/deployment/bootstrap-bluegreen demo -# There MUST be a user with the same name -# as the deployment basename to share data -# between the blue/green deployment. +# NOTE: ENVNAME is also the name of the user who keeps +# shared data in its home directory, so it must exist! +# For demo/test ENVNAMEs, see {demo,test}.sh set -eu @@ -104,3 +104,4 @@ export TALER_ENV_URL_BACKOFFICE="https://backoffice.$ENVNAME.taler.net/" EOL ln -sf "/home/$ENVNAME/shared-data" "$HOME" +mkdir -p "$HOME/sockets" diff --git a/demo.sh b/demo.sh @@ -0,0 +1,14 @@ +#!/bin/bash + +# Every "blue/green" setup relies on a common user that keeps +# all the shared data (keys, for example). In our setup, test-* +# and demo-* rely on the users 'test' and 'demo'. This script +# automates the configuration of the 'demo' user. + +if ! test "demo" = $(whoami); then + echo This script can only be run by the 'demo' user, exiting.. + exit 1 +fi + +echo Creating the 'shared-data' directory. +mkdir $HOME/shared-data diff --git a/test.sh b/test.sh @@ -0,0 +1,14 @@ +#!/bin/bash + +# Every "blue/green" setup relies on a common user that keeps +# all the shared data (keys, for example). In our setup, test-* +# and demo-* rely on the users 'test' and 'demo'. This script +# automates the configuration of the 'demo' user. + +if ! test "test" = $(whoami); then + echo This script can only be run by the 'demo' user, exiting.. + exit 1 +fi + +echo Creating the 'shared-data' directory. +mkdir $HOME/shared-data