From 7981c59502a99b6f7938a18b6ae5c3803cf0a794 Mon Sep 17 00:00:00 2001 From: Stephen Buttolph Date: Thu, 16 Apr 2020 01:03:21 -0400 Subject: Revert "Revert "Added the EVM as a plugin"" --- plugin/main.go | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 plugin/main.go (limited to 'plugin/main.go') diff --git a/plugin/main.go b/plugin/main.go new file mode 100644 index 0000000..f5c9909 --- /dev/null +++ b/plugin/main.go @@ -0,0 +1,21 @@ +package main + +import ( + "github.com/hashicorp/go-plugin" + + "github.com/ava-labs/gecko/vms/rpcchainvm" + + "github.com/ava-labs/coreth/plugin/evm" +) + +func main() { + plugin.Serve(&plugin.ServeConfig{ + HandshakeConfig: rpcchainvm.Handshake, + Plugins: map[string]plugin.Plugin{ + "vm": rpcchainvm.New(&evm.VM{}), + }, + + // A non-nil value here enables gRPC serving for this plugin... + GRPCServer: plugin.DefaultGRPCServer, + }) +} -- cgit v1.2.3-70-g09d2