Lower Docker req to 19, make sure we test locally
continuous-integration/drone/pr Build is passing Details

Ref #15

``` $ docker --version
Docker version 19.03.11, build 42e35e6
```

But abra works. So I think 19 might be sufficient?

Also, wondering if we should add `DOCKER_CONTEXT=default` to that check,
to make sure we're not querying a remote server. (Semi-related question
- should we also check remote Docker versions?)
This commit is contained in:
3wc 2021-03-21 15:39:50 +02:00
parent 36dd6b5eff
commit 65ba113696
1 changed files with 2 additions and 2 deletions

4
abra
View File

@ -479,9 +479,9 @@ require_yq() {
}
require_docker_version (){
major_version=$(docker version --format "{{.Server.Version}}" | cut -d'.' -f1)
major_version=$(DOCKER_CONTEXT=default docker version --format "{{.Server.Version}}" | cut -d'.' -f1)
if [[ "$major_version" -lt 20 ]]; then
if [[ "$major_version" -lt 19 ]]; then
error "This tool requires Docker v20 or greater. Please upgrade your Docker installation"
exit 1
fi