packer-cloudstack icon indicating copy to clipboard operation
packer-cloudstack copied to clipboard

Plugin fails to compile during go get

Open asonix opened this issue 9 years ago • 18 comments

The only info I really have available is the following:

Ubuntu 14.04 Packer 0.7.5 $ go get -u github.com/schubergphilis/packer-cloudstack # github.com/schubergphilis/packer-cloudstack go/src/github.com/schubergphilis/packer-cloudstack/builder.go:77: undefined: packer.ConfigTemplate

asonix avatar Jun 08 '15 20:06 asonix

@asonix thanks for pointing this out! It turns out this is due to a refactoring going on in the core parts of Packer (actual commit causing this: https://github.com/mitchellh/packer/commit/1d3a4d6aa2b2c969bb52f00e27113d21a28ad793). I'll have a look later if we can fix this easily. If not it will require some more time to refactor the CloudStack plugin.

Will try to let you know later today or tomorrow.

svanharmelen avatar Jun 09 '15 08:06 svanharmelen

@asonix I need a little more time for this one... In the mean time you could just checkout packer 0.7.5 and build this plugin with that instead of with the latest master. Would that work for you?

svanharmelen avatar Jun 10 '15 17:06 svanharmelen

I'm still getting this with 0.7.5:

bash-3.2$ packer version Packer v0.7.5

Your version of Packer is out of date! The latest version is 0.8.2. You can update by downloading from www.packer.io bash-3.2$ go get -u github.com/schubergphilis/packer-cloudstack

github.com/schubergphilis/packer-cloudstack

src/github.com/schubergphilis/packer-cloudstack/builder.go:77: undefined: packer.ConfigTemplate

looprock avatar Aug 06 '15 16:08 looprock

Yes... I know... I really have to make some time for this to update this plugin to work with the latest and greatest Packer builds.

Personally I'm actually even more inclined to just convert this plugin to a built-in builder. That would make this separate plugin obsolete and ensures we will always be able to work with Packer and CloudStack.

Will have to schedule some time in the coming weeks to get this done...

svanharmelen avatar Aug 07 '15 10:08 svanharmelen

Any update on this?

eriweb avatar Aug 18 '15 10:08 eriweb

@svanharmelen Great idea getting this built-in to Packer! :+1:

larstobi avatar Aug 18 '15 11:08 larstobi

I'm planning to work on this somewhere next week...

svanharmelen avatar Aug 18 '15 13:08 svanharmelen

@svanharmelen I too am interested in getting this working. Wondering if you've had a chance to look into this?

Are there known working versions of Packer that this plugin is compatible with?

hany avatar Sep 03 '15 11:09 hany

Yeah, I clearly didn't manage to work on this last week :disappointed: It's still on my radar, but have some planning difficulties at the moment. Will try to get back at this one asap...

Not sure, but I think the plugin should work with packer 0.7.5

svanharmelen avatar Sep 03 '15 12:09 svanharmelen

Thanks @svanharmelen. Any idea what the scope of the current issue is? Is it a whole refactor, or just a few adjustments? Is that yet to be determined? Just trying to see if we can also help so it's not all on your shoulders.

hany avatar Sep 03 '15 17:09 hany

I suspect it will be a pretty big refactor... Not only did the packer code change quite a lot recently, I would also like to switch the used CloudStack package to the same one used in other HashiCorp tools (mainly Terraform): https://github.com/xanzy/go-cloudstack

So it's definitely more then just some tweaking and updating I'm afraid.

svanharmelen avatar Sep 04 '15 09:09 svanharmelen

packer-cloudstack still compiles fine with packer 0.7.5, however packer 0.7.5 doesn't compile any longer either. A workaround is to go get packer, delete the compiled packer binaries it builds, check out the 0.7.5 tag, then download the precompiled 0.7.5 release and place the binaries as if 0.7.5 compiled successfully. Then I can build packer-cloudstack.

larstobi avatar Sep 04 '15 10:09 larstobi

Thanks for the clarification.

I wonder if anyone knows of a plugin or other method to get Packer to produce VHD files? That could be a decent workaround for now.

hany avatar Sep 04 '15 12:09 hany

Hey Guys,

FYI, one of our team members went a different route and wrote a Packer post-processor that converts a VirtualBox image into a VHD:

https://github.com/benwebber/packer-post-processor-vhd

Just thought we'd share.

hany avatar Sep 14 '15 19:09 hany

Have you published your half done port somewhere, @svanharmelen ?

larstobi avatar Aug 17 '16 07:08 larstobi

No, I didn't... And by now it's hopelessly out-of-date again 😞

As the holidays are now over, I'm planning to start working again by picking up two tasks that are both long past due. This being one of them...

So I'll be working again on this in the coming week(s) and hope I have the space and time to finish it up before being hit with a wall of other work again :wink:

svanharmelen avatar Aug 22 '16 09:08 svanharmelen

I know, I know... It took waaaaay to long, but here it is: https://github.com/mitchellh/packer/pull/3909

svanharmelen avatar Sep 21 '16 18:09 svanharmelen

I guess this issue should probably be closed for a while now already 😏

svanharmelen avatar Apr 05 '23 13:04 svanharmelen