Mercurial > hg
changeset 27103:2d437a0f3355 stable 3.6.2
docker: match more version of 'hg docker version' (issue4967)
My version of docker (1.8.3) have a different formating for 'docker version'
that broke the build script. We make the version matching more generic in to
work with both version.
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Tue, 24 Nov 2015 18:13:25 -0800 |
parents | f97bb61b51e6 |
children | 33cb39084a1e |
files | contrib/dockerlib.sh |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/contrib/dockerlib.sh Mon Nov 30 16:31:28 2015 -0800 +++ b/contrib/dockerlib.sh Tue Nov 24 18:13:25 2015 -0800 @@ -14,8 +14,8 @@ fi $DOCKER -h 2> /dev/null | grep -q Jansens && { echo "Error: $DOCKER is the Docking System Tray - install docker.io instead"; exit 1; } - $DOCKER version | grep -q "^Client version:" || { echo "Error: unexpected output from \"$DOCKER version\""; exit 1; } - $DOCKER version | grep -q "^Server version:" || { echo "Error: could not get docker server version - check it is running and your permissions"; exit 1; } + $DOCKER version | grep -Eq "^Client( version)?:" || { echo "Error: unexpected output from \"$DOCKER version\""; exit 1; } + $DOCKER version | grep -Eq "^Server( version)?:" || { echo "Error: could not get docker server version - check it is running and your permissions"; exit 1; } } # Construct a container and leave its name in $CONTAINER for future use.