Azure / packer-azure

Packer for Azure
MIT License
115 stars 50 forks source link

Build failure smap/win and azure/arm #203

Closed aaronbareford closed 8 years ago

aaronbareford commented 8 years ago

Hello,

I encountered some issues when trying to build packer-azure go get github.com/Azure/packer-azure/packer/plugin/... today.

github.com/Azure/packer-azure/packer/builder/azure/smapi/win fails withr: `*azureVmCustomScriptExtension.comm does not implement packer.Communicator (missing DownloadDir method)

github.com/Azure/packer-azure/packer/builder/azure/arm fails with: *"github.com/mitchellh/packer/common".StepProvision does not implement "github.com/mitchellh/multistep".Step (wrong type for Cleanup method) have Cleanup("github.com/mitchellh/packer/vendor/github.com/mitchellh/multistep".StateBag) want Cleanup("github.com/mitchellh/multistep".StateBag)

Build output messages:

root@vagrant-ubuntu-trusty-64:~# go get github.com/Azure/packer-azure/packer/plugin/...
# github.com/Azure/packer-azure/packer/builder/azure/smapi/win
work/src/github.com/Azure/packer-azure/packer/builder/azure/smapi/win/step_set_provision_infrastructure.go:91: cannot convert comm (type *azureVmCustomScriptExtension.comm) to type packer.Communicator:
    *azureVmCustomScriptExtension.comm does not implement packer.Communicator (missing DownloadDir method)
go build github.com/mitchellh/packer/vendor/github.com/ugorji/go/codec: /usr/local/go/pkg/tool/linux_amd64/compile: signal: killed
# github.com/Azure/packer-azure/packer/builder/azure/arm
work/src/github.com/Azure/packer-azure/packer/builder/azure/arm/builder.go:73: cannot use lin.SSHHost (type func("github.com/mitchellh/multistep".StateBag) (string, error)) as type func("github.com/mitchellh/packer/vendor/github.com/mitchellh/multistep".StateBag) (string, error) in field value
work/src/github.com/Azure/packer-azure/packer/builder/azure/arm/builder.go:74: cannot use lin.SSHConfig(b.config.UserName) (type func("github.com/mitchellh/multistep".StateBag) (*"golang.org/x/crypto/ssh".ClientConfig, error)) as type func("github.com/mitchellh/packer/vendor/github.com/mitchellh/multistep".StateBag) (*"github.com/mitchellh/packer/vendor/golang.org/x/crypto/ssh".ClientConfig, error) in field value
work/src/github.com/Azure/packer-azure/packer/builder/azure/arm/builder.go:76: cannot use "github.com/mitchellh/packer/common".StepProvision literal (type *"github.com/mitchellh/packer/common".StepProvision) as type "github.com/mitchellh/multistep".Step in array or slice literal:
    *"github.com/mitchellh/packer/common".StepProvision does not implement "github.com/mitchellh/multistep".Step (wrong type for Cleanup method)
        have Cleanup("github.com/mitchellh/packer/vendor/github.com/mitchellh/multistep".StateBag)
        want Cleanup("github.com/mitchellh/multistep".StateBag)
work/src/github.com/Azure/packer-azure/packer/builder/azure/arm/builder.go:123: cannot use "github.com/mitchellh/packer/common".MultistepDebugFn(ui) (type "github.com/mitchellh/packer/vendor/github.com/mitchellh/multistep".DebugPauseFn) as type "github.com/mitchellh/multistep".DebugPauseFn in field value

System: go version go1.6 linux/amd64 ubuntu 14.04

If I can provide any more information to help track down this issue, please let me know.

Thanks, Aaron

boumenot commented 8 years ago

Thanks for opening an issue!

Packer recently started vendoring their dependencies, which broke my local build too. I opened a PR against the packer repo to "fix" it, but my "fix" was wrong. Chris (@cbednarski) provided the real fix, which is to use godep. Please see that PR for details.

We are working on merging the two repos, so this will problem will no longer exist. We'll be ready to merge once the pending ARM issues are addressed.

HTH, Christopher

paulmey commented 8 years ago

I found the same issue... our 'custom script' communicator doesn't yet have the new DownloadDir method that was added in https://github.com/mitchellh/packer/commit/feee19e4ed51e9045e4de6639b4b954f5ac37e58

boumenot commented 8 years ago

Thanks Paul, I clearly missed the obvious.

aaronbareford commented 8 years ago

Thanks for the quick response @boumenot @paulmey. I was able to build locally following the linked PR.