signed-commit remote shell (see also https://github.com/dyne/scorsh)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
scorsh/test/create_testbed.sh

49 lines
1022 B

#!/bin/sh
##
## This script is part of the scorsh testbed. It must be executed by
## the scorsh_testsuite script
##
. ./scorsh_functions
### remove the directories if they exist already
[ -d ${REMOTE_REPO} ] && rm -rf ${REMOTE_REPO}
[ -d ${LOCAL_REPO} ] && rm -rf ${LOCAL_REPO}
### create the repository
git init --bare ${REMOTE_REPO}
check "[ $? -eq 0 ]" $0 "create_remote_repo"
### clone it
git clone ${REMOTE_REPO} ${LOCAL_REPO}
check "[ $? -eq 0 ]" $0 "clone_remote_repo"
### create the directory where scorsh will be cloned
mkdir ${SCORSH_REPO}
check "[ $? -eq 0 ]" $0 "create_scorsh_repo_folder"
### clone the scorsh repo
olddir=$(pwd)
cd ${SCORSH_REPO}
git clone ${SCORSH_URL} ./
check "[ $? -eq 0 ]" $0 "clone_scorsh_repo"
cd ${olddir}
### make the scorshd executable
olddir=$(pwd)
cd ${SCORSH_REPO}
make
check "[ $? -eq 0 ]" $0 "make_scorshd"
cd ${olddir}
### create the directory where the scorsh app will run
mkdir ${SCORSH_APP}
check "[ $? -eq 0 ]" $0 "create_scorsh_app_folder"
return_results