|
@ -76,7 +76,7 @@ else |
|
|
|
|
|
|
|
|
#check if docker UP |
|
|
#check if docker UP |
|
|
dockerserverdown=$(docker info --format "{{json .}}" | jq .ServerErrors) |
|
|
dockerserverdown=$(docker info --format "{{json .}}" | jq .ServerErrors) |
|
|
if [[ $dockerversion =~ *"permission denied"* ]]; then |
|
|
if [[ $dockerversion == *denied1* ]]; then |
|
|
echo "" |
|
|
echo "" |
|
|
echo "docker server is down" |
|
|
echo "docker server is down" |
|
|
echo "" |
|
|
echo "" |
|
@ -97,7 +97,7 @@ else |
|
|
|
|
|
|
|
|
#check docker version |
|
|
#check docker version |
|
|
dockerversion=$(docker info --format "{{json .}}" | jq .ServerVersion | cut -d'.' -f1) |
|
|
dockerversion=$(docker info --format "{{json .}}" | jq .ServerVersion | cut -d'.' -f1) |
|
|
if [ ! -z $dockerversion ];then |
|
|
if [[ ! -z $dockerversion && $dockerversion != 'null' ]] ;then |
|
|
dockerversion="${dockerversion#\"}" |
|
|
dockerversion="${dockerversion#\"}" |
|
|
if [ $dockerversion -lt 19 ];then |
|
|
if [ $dockerversion -lt 19 ];then |
|
|
echo "" |
|
|
echo "" |
|
|