aboutsummaryrefslogtreecommitdiff
path: root/plugin/main.go
diff options
context:
space:
mode:
authorAaron Buchwald <[email protected]>2020-10-20 11:57:31 -0400
committerAaron Buchwald <[email protected]>2020-10-20 11:57:31 -0400
commit6da65c2173e6da457423d67e958ce153c5598a17 (patch)
treea4e89b92bdebee9f7a2522a0bf0cf1ada394c9c5 /plugin/main.go
parenta02b51064dcb5e4fe062237635d2b986591630f0 (diff)
Add CLI config to coreth plugin
Diffstat (limited to 'plugin/main.go')
-rw-r--r--plugin/main.go7
1 files changed, 6 insertions, 1 deletions
diff --git a/plugin/main.go b/plugin/main.go
index c79a305..b42ba14 100644
--- a/plugin/main.go
+++ b/plugin/main.go
@@ -1,6 +1,8 @@
package main
import (
+ "fmt"
+
"github.com/hashicorp/go-plugin"
"github.com/ava-labs/avalanchego/vms/rpcchainvm"
@@ -9,10 +11,13 @@ import (
)
func main() {
+ if errs.Errored() {
+ panic(fmt.Sprintf("Errored while parsing Coreth CLI Config: %w", errs.Err))
+ }
plugin.Serve(&plugin.ServeConfig{
HandshakeConfig: rpcchainvm.Handshake,
Plugins: map[string]plugin.Plugin{
- "vm": rpcchainvm.New(&evm.VM{}),
+ "vm": rpcchainvm.New(&evm.VM{CLIConfig: cliConfig}),
},
// A non-nil value here enables gRPC serving for this plugin...