Skip to content

Commit

Permalink
Improve docker/parallels detection
Browse files Browse the repository at this point in the history
  • Loading branch information
tomjn authored Jul 10, 2024
1 parent f375014 commit e43c3a0
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -42,17 +42,13 @@ end


def vvv_is_docker_present()
VagrantPlugins::DockerProvider::Driver.new.execute("docker", "version")
return true
rescue Vagrant::Errors::CommandUnavailable
return false
if system("docker version")
return true
end
end

def vvv_is_parallels_present()
VagrantPlugins::DockerProvider::Driver.new.execute("prctl", "version")
return true
rescue Vagrant::Errors::CommandUnavailable
return false
return Vagrant.has_plugin?("vagrant-parallels")
end

vagrant_dir = __dir__
Expand Down

0 comments on commit e43c3a0

Please sign in to comment.