Closed hc-github-team-packer closed 2 years ago
-parallel-builds=1
works around this problem for me, so that each docker-push runs sequentially, logging in to ECR then logging out before the next docker-push.
Hi @kenit @hertzsprung thanks again for reporting, this should be fixed by #96. The changes in the PR modify the docker-push post processor to use a temporary, isolated Docker client configuration directory per post-processor run, which should prevent Packer from creating shared credential files. There are some test binaries available via the link below if you would like to test the fix before the next release. https://app.circleci.com/pipelines/github/hashicorp/packer-plugin-docker/107/workflows/0599fc6d-d791-4430-980e-b23e86604963/jobs/1433/artifacts
This issue was originally opened by @kenit in https://github.com/hashicorp/packer/issues/11358 and has been migrated to this repository. The original issue description is below.
Overview of the Issue
I am trying to build two images in parallel base on two different version PHP image and to push artifacts into AWS ECR. When one of two artifacts is pushed to ECR, Packer will remove the login credential of ECR and break the push process of another artifact.
Packer version
1.7.7
Simplified Packer Template
Operating system and Environment details
OS: Ubuntu
Log Fragments and crash.log files