Return an ActionResp
This commit is contained in:
parent
41f3af51af
commit
773c4bd910
@ -193,6 +193,9 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
||||
end
|
||||
add_message "hashicorp.vagrant.sdk.Provider.ActionResp" do
|
||||
optional :result, :message, 1, "google.protobuf.Any"
|
||||
map :labels, :string, :string, 2
|
||||
optional :template_data, :bytes, 3
|
||||
optional :success, :bool, 4
|
||||
end
|
||||
add_message "hashicorp.vagrant.sdk.Communicator" do
|
||||
end
|
||||
|
||||
@ -1,18 +0,0 @@
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: plugin_server.proto
|
||||
|
||||
require 'google/protobuf'
|
||||
|
||||
Google::Protobuf::DescriptorPool.generated_pool.build do
|
||||
add_file("plugin_server.proto", :syntax => :proto3) do
|
||||
add_message "hashicorp.vagrant.UpResult" do
|
||||
optional :success, :bool, 1
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
module Hashicorp
|
||||
module Vagrant
|
||||
UpResult = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("hashicorp.vagrant.UpResult").msgclass
|
||||
end
|
||||
end
|
||||
@ -1,8 +0,0 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package hashicorp.vagrant;
|
||||
|
||||
message UpResult {
|
||||
bool success = 1;
|
||||
}
|
||||
|
||||
@ -1,7 +1,6 @@
|
||||
|
||||
require 'proto/gen/plugin/plugin_pb'
|
||||
require 'proto/gen/plugin/plugin_services_pb'
|
||||
require 'proto/gen/plugin/plugin_server_pb'
|
||||
require 'vagrant/machine'
|
||||
require 'logger'
|
||||
|
||||
@ -38,7 +37,7 @@ module VagrantPlugins
|
||||
def action_up(req, _unused_call)
|
||||
machine = machine_arg_to_machine(req)
|
||||
LOG.debug(machine)
|
||||
Hashicorp::Vagrant::UpResult.new(success: true)
|
||||
Hashicorp::Vagrant::Sdk::Provider::ActionResp.new(success: true)
|
||||
end
|
||||
|
||||
def machine_arg_to_machine(req)
|
||||
@ -63,11 +62,10 @@ module VagrantPlugins
|
||||
]
|
||||
result = [
|
||||
Hashicorp::Vagrant::Sdk::FuncSpec::Value.new(
|
||||
type: "hashicorp.vagrant.UpResult",
|
||||
type: "hashicorp.vagrant.sdk.Provider.ActionResp",
|
||||
name: ""
|
||||
),
|
||||
]
|
||||
|
||||
Hashicorp::Vagrant::Sdk::FuncSpec.new(
|
||||
args: args,
|
||||
result: result
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user