Hello,
I try to upload my box with vagrant-cloud post-processor.
But it failed with an error below.
Build 'hyperv-iso' errored: 1 error(s) occurred:
* Post-processor failed: Unknown artifact type, requires box from vagrant
post-processor or vagrant builder: MSOpenTech.hyperv
I configured my packer that it creates the box for hyperv using hyperv-iso
builder and run the vagrant post-processor prior the vagrant-cloud
post-processor.
I am not sure but I expect that it can be worked as long as I am using the
vagrant post-processor from the message showed.
The post-processors part of my source code is:
"post-processors": [
{
"type": "vagrant",
"keep_input_artifact": false,
"output": "windows10_{{.Provider}}.box",
"vagrantfile_template": "vagrantfile-windows10.template"
},
{
"type": "vagrant-cloud",
"box_tag": "ymasuda/windows10",
"access_token": "{{user `cloud_token`}}",
"version": "{{user `version`}}"
}
],
I configured it following the example which showed in the vagrant-cloud
page of the official help page.
See whole packer template in https://github.com/yusukemasuda/packer-windows
if you need.
Please be aware the one that it is before adding the vagrant-cloud
post-processor, I added the code above and its variables on it.
I also took a look the packer source code in GitHub.
https://github.com/hashicorp/packer/blob/master/post-processor/vagrant-cloud/post-processor.go
var builtins = map[string]string{
"mitchellh.post-processor.vagrant": "vagrant",
"packer.post-processor.artifice": "artifice",
"vagrant": "vagrant",
}
:
:
func (p *PostProcessor) PostProcess(ctx context.Context, ui packer.Ui,
artifact packer.Artifact) (packer.Artifact, bool, bool, error) {
if _, ok := builtins[artifact.BuilderId()]; !ok {
return nil, false, false, fmt.Errorf(
"Unknown artifact type, requires box from vagrant
post-processor or vagrant builder: %s", artifact.BuilderId())
}
Will it really work with just using vagrant post-processor, even if I use
the hyperv builder?
The source code seemingly expecting some combinations.
Can I use vagrant-cloud post-processor even if I am using hyperv builder?
Regards,
Yusuke.
--
This mailing list is governed under the HashiCorp Community Guidelines -
https://www.hashicorp.com/community-guidelines.html. Behavior in violation of
those guidelines may result in your removal from this mailing list.
GitHub Issues: https://github.com/mitchellh/packer/issues
IRC: #packer-tool on Freenode
---
You received this message because you are subscribed to the Google Groups
"Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/packer-tool/ea037e68-b7d9-45d2-b0a2-4302b556e73d%40googlegroups.com.