alibaba / packer-provider

Apache License 2.0
92 stars 26 forks source link

build error #46

Closed sudpf closed 5 years ago

sudpf commented 5 years ago

panic: gob: registering duplicate names for map[string]interface {}: "map[string]interface {}" != "map[string]interface {}"

goroutine 1 [running]: encoding/gob.RegisterName(0x204e6f6, 0x18, 0x2151ec0, 0xc42020a920) /usr/local/golang/src/encoding/gob/type.go:826 +0x4cc encoding/gob.Register(0x2151ec0, 0xc42020a920) /usr/local/golang/src/encoding/gob/type.go:874 +0x127 github.com/hashicorp/packer/packer/rpc.init.0() /home/src/github.com/hashicorp/packer/packer/rpc/init.go:6 +0x41 github.com/hashicorp/packer/packer/rpc.init()

:1 +0x89 github.com/hashicorp/packer/packer/plugin.init() :1 +0x5f api/packer.init() :1 +0x67 api.init() :1 +0x5d main.init() :1 +0x4e
sudpf commented 5 years ago

env centos7 golang1.9

chhaj5236 commented 5 years ago

@liyuzhu1984 Could you please provide your command and configuration file to us. We'll see if we can reproduce the error. Thanks for your contribution.

sudpf commented 5 years ago

no configuration file, i just run it after compile, and then panic。

chhaj5236 commented 5 years ago

@liyuzhu1984 How did you compile this provider? Since we do not encounter the issue you mentioned, more details would be helpful to reproduce.

sudpf commented 5 years ago

import ( "github.com/alibaba/packer-provider/alicloud-import" "github.com/alibaba/packer-provider/ecs" "github.com/hashicorp/packer/packer/plugin" )

func NewPackerCtl() *PackerCtl { server.RegisterBuilder(new(ecs.Builder)) server.RegisterPostProcessor(new(alicloudimport.PostProcessor)) server.Serve() }

i add the code to myself project, so i can do packer by my program. NewPackerCtl will be call in my
init function.

chhaj5236 commented 5 years ago

@liyuzhu1984 This seems not a packer-provider issue. You might need more investigations about your project codes. I'll close this issue for now, if you found anything related to this provider, please let us know. Thanks for your contribution.