Using PR #1, I built the plugin as follows:
go get -d ./... && go build
I then copied the resulting binaries to the bin directory in my path, alongside packer.
bin Contents
❯ ls ~/git/bin/packer* [16:28:23]
/home/tyler/git/bin/packer /home/tyler/git/bin/packer-post-processor-docker-dockerfile
/home/tyler/git/bin/packer-builder-amazon-chroot /home/tyler/git/bin/packer-post-processor-docker-import
/home/tyler/git/bin/packer-builder-amazon-ebs /home/tyler/git/bin/packer-post-processor-docker-push
/home/tyler/git/bin/packer-builder-amazon-instance /home/tyler/git/bin/packer-post-processor-docker-save
/home/tyler/git/bin/packer-builder-digitalocean /home/tyler/git/bin/packer-post-processor-docker-tag
/home/tyler/git/bin/packer-builder-docker /home/tyler/git/bin/packer-post-processor-vagrant
/home/tyler/git/bin/packer-builder-file /home/tyler/git/bin/packer-post-processor-vagrant-cloud
/home/tyler/git/bin/packer-builder-googlecompute /home/tyler/git/bin/packer-post-processor-vsphere
/home/tyler/git/bin/packer-builder-null /home/tyler/git/bin/packer-provisioner-ansible-local
/home/tyler/git/bin/packer-builder-openstack /home/tyler/git/bin/packer-provisioner-chef-client
/home/tyler/git/bin/packer-builder-parallels-iso /home/tyler/git/bin/packer-provisioner-chef-solo
/home/tyler/git/bin/packer-builder-parallels-pvm /home/tyler/git/bin/packer-provisioner-file
/home/tyler/git/bin/packer-builder-qemu /home/tyler/git/bin/packer-provisioner-powershell
/home/tyler/git/bin/packer-builder-virtualbox-iso /home/tyler/git/bin/packer-provisioner-puppet-masterless
/home/tyler/git/bin/packer-builder-virtualbox-ovf /home/tyler/git/bin/packer-provisioner-puppet-server
/home/tyler/git/bin/packer-builder-vmware-iso /home/tyler/git/bin/packer-provisioner-salt-masterless
/home/tyler/git/bin/packer-builder-vmware-vmx /home/tyler/git/bin/packer-provisioner-shell
/home/tyler/git/bin/packer-post-processor-artifice /home/tyler/git/bin/packer-provisioner-shell-local
/home/tyler/git/bin/packer-post-processor-atlas /home/tyler/git/bin/packer-provisioner-windows-restart
/home/tyler/git/bin/packer-post-processor-compress /home/tyler/git/bin/packer-provisioner-windows-shell
I don't have issues with any other post-processors (so far). I've successfully used the docker-tag post-processor. Removing it from my Packer template does not change anything: the failure occurs in the same way. I've also tried using export_path instead of commit, but this resulted in a different error.
"commit": true Error
==> docker: Committing the container
docker: Image ID: 093081626c7155fdc4c5773e837e0845bcd08b3b4d2636c5b65a7ab4da3d840d
==> docker: Killing the container: b46964e6982c4119006482140a6351589751edfb8ac5c83a820e0ea640c1cd0e
==> docker: Running post-processor: docker-dockerfile
docker (docker-dockerfile): Base image ID: 093081626c7155fdc4c5773e837e0845bcd08b3b4d2636c5b65a7ab4da3d840d
Build 'docker' errored: 1 error(s) occurred:
* Post-processor failed: Error building image: exit status 1
Stderr: unable to process Dockerfile: unable to parse repository info: Invalid repository name (093081626c7155fdc4c5773e837e0845bcd08b3b4d2636c5b6
5a7ab4da3d840d), cannot specify 64-byte hexadecimal strings
==> Some builds didn't complete successfully and had errors:
--> docker: 1 error(s) occurred:
* Post-processor failed: Error building image: exit status 1
Stderr: unable to process Dockerfile: unable to parse repository info: Invalid repository name (093081626c7155fdc4c5773e837e0845bcd08b3b4d2636c5b6
5a7ab4da3d840d), cannot specify 64-byte hexadecimal strings
"export_path": "image.tar" Error
* Post-processor failed: Unknown artifact type: packer.docker
Can only build with Dockerfile from Docker builder artifacts.
Packer Template
{
"builders":[{
"type": "docker",
"image": "debian",
"commit": true
}],
"provisioners":[
{
"type": "shell",
"inline": ["apt-get -yqq update", "apt-get -yqq install curl"]
},
{
"type": "chef-solo",
"cookbook_paths": ["cookbooks"],
"data_bags_path": "data_bags",
"run_list": ["atom::default", "pyde::default"],
"prevent_sudo": true
}
],
"post-processors": [
[{
"type": "docker-dockerfile",
"maintainer": "Tyler Christiansen <code@tylerc.me>",
"entrypoint": "/usr/bin/atom",
"user": "tyler"
}, {
"type": "docker-tag",
"repository": "supertylerc/pyde",
"tag": "latest"
}]
]
}
Versions
# Docker version
❯ docker -v
Docker version 1.9.1, build a34a1d5-dirty
# docker-dockerfile post-processor commit hash
❯ git rev-parse HEAD
a4ec7b5361d909555b5b23b94cf574cdf5e1fcae
# Packer version
❯ packer -v
0.8.6
Using PR #1, I built the plugin as follows:
I then copied the resulting binaries to the
bindirectory in my path, alongsidepacker.binContentsI don't have issues with any other post-processors (so far). I've successfully used the
docker-tagpost-processor. Removing it from my Packer template does not change anything: the failure occurs in the same way. I've also tried usingexport_pathinstead ofcommit, but this resulted in a different error."commit": trueError"export_path": "image.tar"ErrorPacker Template
{ "builders":[{ "type": "docker", "image": "debian", "commit": true }], "provisioners":[ { "type": "shell", "inline": ["apt-get -yqq update", "apt-get -yqq install curl"] }, { "type": "chef-solo", "cookbook_paths": ["cookbooks"], "data_bags_path": "data_bags", "run_list": ["atom::default", "pyde::default"], "prevent_sudo": true } ], "post-processors": [ [{ "type": "docker-dockerfile", "maintainer": "Tyler Christiansen <code@tylerc.me>", "entrypoint": "/usr/bin/atom", "user": "tyler" }, { "type": "docker-tag", "repository": "supertylerc/pyde", "tag": "latest" }] ] }Versions