Closed K4ybedenler closed 5 months ago
Hi @K4ybedenler,
This issue being tied to the Docker plugin, I transferred it over.
I'm not sure what's the error you're getting from, could you docker inspect
the image by any chance?
I suspect the entrypoint was left as-is from the origin in v1.0.8, which is something that changed with v1.0.9 (#167 is where we introduced that change), looking back at it, someone else reported this change being problematic for them, so this is something we need to address.
In the meantime, I believe you can workaround the bug either by fixing the plugin version to 1.0.8, or by defining your own entrypoint/cmd in the template you're using.
Sorry about that blunder, we'll try to push a fix ASAP.
could you docker inspect the image by any chance?
sure, here is:
[
{
"Id": "sha256:57fcfba27f8637f891b4c895e5a4c42a46af93223210e565cf42fab45628d1c2",
"RepoTags": [],
"RepoDigests": [],
"Parent": "sha256:52882761a72a60649edff9a2478835325d084fb640ea32a975e29e12a012025f",
"Comment": "",
"Created": "2024-05-16T19:53:12.679823765Z",
"DockerVersion": "26.1.2",
"Author": "",
"Config": {
"Hostname": "e2367c1e61fd",
"Domainname": "",
"User": "",
"AttachStdin": false,
"AttachStdout": false,
"AttachStderr": false,
"Tty": true,
"OpenStdin": true,
"StdinOnce": false,
"Env": [
"PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
],
"Cmd": [
"/bin/bash"
],
"Image": "ubuntu:jammy",
"Volumes": null,
"WorkingDir": "",
"Entrypoint": [
"/bin/sh"
],
"OnBuild": null,
"Labels": {
"org.opencontainers.image.ref.name": "ubuntu",
"org.opencontainers.image.version": "22.04"
}
},
"Architecture": "amd64",
"Os": "linux",
"Size": 77859496,
"GraphDriver": {
"Data": {
"LowerDir": "/var/lib/docker/overlay2/37c05d2353952625c162c829b1ef5b76ddbc89c81ff1263e5772168f4f3829f5/diff",
"MergedDir": "/var/lib/docker/overlay2/08438d4ceb7e88397825f143107a3ce08beaa689f7f20d4e42ca45ff0a7c291c/merged",
"UpperDir": "/var/lib/docker/overlay2/08438d4ceb7e88397825f143107a3ce08beaa689f7f20d4e42ca45ff0a7c291c/diff",
"WorkDir": "/var/lib/docker/overlay2/08438d4ceb7e88397825f143107a3ce08beaa689f7f20d4e42ca45ff0a7c291c/work"
},
"Name": "overlay2"
},
"RootFS": {
"Type": "layers",
"Layers": [
"sha256:629ca62fb7c791374ce57626d6b8b62c76378be091a0daf1a60d32700b49add7",
"sha256:24359aea1b3db3432f4af2488e76609e07b72f814f6c0c2b98c6a1e1454d6dcc"
]
},
"Metadata": {
"LastTagTime": "0001-01-01T00:00:00Z"
}
}
]
Hi @K4ybedenler,
I managed to take a look at this, and I think I have a fix that should work for your situation on the PR I mention in this thread. If you can, might I ask you to build the plugin on this branch, install it, and try again with your template? I tried it locally and it does seem to work, but one can never be too sure, and I would appreciate if you were able to test it before we can release.
Thanks!
@lbajolet-hashicorp hi, sorry that didn't answer earlier! but it seems fixed. thanks for your job!
packer version 1.0.9.
similar problem in such tickets: 7578, 2697
I'm going with the tutorial, theme "Add provisioner to template"
my docker-ubuntu.pkr.hcl is:
everything ok on the build stage:
but after it failes to run:
in 1.0.8 everything is ok