Allows default image to be specified
This commit is contained in:
parent
48cd7ca5ca
commit
ffe4577a4f
2 changed files with 5 additions and 3 deletions
|
@ -3,3 +3,4 @@ export PROJECTS_DIR="${HOME}/Projects"
|
|||
# The following are to configure devenv
|
||||
export DEVENV_DIR=$PROJECTS_DIR/devenv
|
||||
export DEVENV_REPO="ssh://git@repobase.net/j/devenv.git"
|
||||
export DEVENV_IMG=base
|
||||
|
|
|
@ -6,12 +6,13 @@
|
|||
## For more information, checkout repobase.net/j/devenv
|
||||
|
||||
[ -z $DEVENV_DIR ] && MSG="Please define DEVENV_DIR in config" failout
|
||||
[ -z $DEVENV_REPO ] && MSG="Please define DEVENV_DIR in config" failout
|
||||
[ -z $DEVENV_REPO ] && MSG="Please define DEVENV_REPO in config" failout
|
||||
[ -z $DEVENV_IMG ] && MSG="Please define DEVENV_IMG in config" failout
|
||||
|
||||
[ -f $DEVENV_DIR ] && MSG="DEVENV_DIR points to a file. Wtf?" failout
|
||||
[ -d $DEVENV_DIR ] || git clone $DEVENV_REPO $DEVENV_DIR
|
||||
|
||||
[ -z "$1" ] && IMAGE='base' || IMAGE=$1
|
||||
[ -z "$1" ] && IMAGE=$DEVENV_IMG || IMAGE=$1
|
||||
|
||||
cd $DEVENV_DIR
|
||||
bash run.sh $IMAGE
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue