Permalink
Browse files

Add pre-flight tests

  • Loading branch information...
SamSaffron committed Mar 21, 2014
1 parent dda0e62 commit a3e18d952f053bc88b852422cad79eebdcb2d483
Showing with 33 additions and 0 deletions.
  1. +33 −0 launcher
View
@@ -29,6 +29,39 @@ usage () {
exit 1
}
prereqs() {
# 1. running aufs
test=`docker info 2> /dev/null | grep 'Driver: aufs'`
if [[ "$test" =~ "aufs" ]] ; then : ; else
echo "Your Docker installation is not using aufs"
echo "Device mapper and other experimental drivers are unstable"
echo
echo "Please ensure your kernel is running linux extras and aufs"
echo "Please follow the installation guide for Docker here: http://docs.docker.io/en/latest/installation/ubuntulinux/"
exit 1
fi
# 2. running docker 0.9+
test=`docker --version | grep 0.9`
if [[ "$test" =~ "0.9" ]] ; then : ; else
echo "Your Docker installation is old, please upgrade to 0.9.0 or up"
exit 1
fi
# 3. able to attach stderr / out / tty
test=`docker run -i -t --rm -a stdin -a stdout -a stderr $image echo working`
if [[ "$test" =~ "working" ]] ; then : ; else
echo "Your Docker installation is not working correctly"
echo
echo "See: https://meta.discourse.org/t/docker-error-on-bootstrap/13657/18?u=sam"
exit 1
fi
}
prereqs
install_docker() {
echo "Docker is not installed, make sure you are running on the 3.8 kernel"

0 comments on commit a3e18d9

Please sign in to comment.