dubdiff/docker/mean
Adam Brown 3bf6223c92 Add 'docker/' from commit '697f105a275dab12b3cc0200a25b067d1f263e8c'
git-subtree-dir: docker
git-subtree-mainline: f27d91a803
git-subtree-split: 697f105a27
2015-04-17 13:00:37 -04:00

19 lines
742 B
Bash
Executable File

#!/bin/bash
# launch the mean docker container to execute a single command on the working directory
# the working directory will be mounted as /working in the docker container
# test if the data-docker-home container has been created
if docker inspect -f {{.Name}} data-docker-home > /dev/null
then
echo > /dev/null
else
echo "* creating data-docker-home container"
echo
# The data container has a volume at /home/docker, is named 'data' and is based on busybox
docker create -v /home/docker --name data-docker-home adamarthurryan/mean echo "Data container - docker home"
fi
docker run -it --rm --volumes-from=data-docker-home -v ${PWD}:/working -w /working -p 9000:9000 -p 35729:35729 adamarthurryan/mean $@