remove jq usage

Signed-off-by: Carlos Santana <csantana23@gmail.com>
This commit is contained in:
Carlos Santana 2022-03-04 07:11:37 -05:00
parent b8bd6f190b
commit e914f6bf20

View File

@ -189,7 +189,7 @@ function kube::build::verify_prereqs() {
function kube::build::docker_available_on_osx() {
if [[ -z "${DOCKER_HOST}" ]]; then
if [[ -S "/var/run/docker.sock" ]] || [[ -S "$(docker context inspect | jq -r '.[0].Endpoints.docker.Host' | awk -F 'unix://' '{print $2}')" ]]; then
if [[ -S "/var/run/docker.sock" ]] || [[ -S "$(docker context inspect --format '{{.Endpoints.docker.Host}}' | awk -F 'unix://' '{print $2}')" ]]; then
kube::log::status "Using docker on macOS"
return 0
fi