diff --git a/lib/vagrant/box_collection/remote.rb b/lib/vagrant/box_collection/remote.rb index 7644b991d..ec25700e1 100644 --- a/lib/vagrant/box_collection/remote.rb +++ b/lib/vagrant/box_collection/remote.rb @@ -33,7 +33,12 @@ module Vagrant # @return [Array] Array of `[name, version, provider]` of the boxes # installed on this system. def all - client.all + all_boxes = client.all + boxes = [] + all_boxes.each do |b| + boxes << [b.name, b.version, b.provider] + end + boxes end # @return [Box] The box found, or `nil` if not found. diff --git a/plugins/commands/serve/client/box_collection.rb b/plugins/commands/serve/client/box_collection.rb index 96e3a8519..95a029f8d 100644 --- a/plugins/commands/serve/client/box_collection.rb +++ b/plugins/commands/serve/client/box_collection.rb @@ -46,9 +46,9 @@ module VagrantPlugins end # @return [Vagrant::Box] box found - def find(name, providers, versions) + def find(name, providers, version) res = client.find(SDK::BoxCollection::FindRequest.new( - name: name, version: version, providers: providers + name: name, version: version, providers: Array(providers) )) box_client = Box.load(res, broker: broker) box = Vagrant::Box.new(