Closed matthewpwilson closed 4 years ago
@scottkurz please review
Thinking about this further I've realised my testing isn't sufficient to prove my fix does the job.... I'll close the PR for now until I've proved it
I believe this is fine - I tested by pushing my new stack image to Dockerhub, and changed my project's .appsody-config.yaml to point at it. If I understand correctly Appsody will pick up the new Dockerfile from the stack image and use that for appsody build
. This works correctly with my fix in place.
@Kamran64 we can build this:
Fix docker bug hit during
appsody build
: failed to export image: failed to create image: failed to get layer
Thanks
Checklist:
[x] Read the Code of Conduct and Contributing Guidelines.
[x] Followed the commit message guidelines.
[x] Stack adheres to Appsody stack structure.
Modifying an existing stack:
stack.yaml
When trying to do an
appsody build
using the java-openliberty stack in a GitHub Actions, CI environment, I hit the following error:This appears to be caused by moby/moby#37965. The characteristics of the
COPY
don't exactly match the description in the issue but the symptom is the same. This issue has been open for a while and there's no sign of a fix so I think it's worth putting a workaround in the stack. I've added the suggestedRUN true
, which fixes the issue for me. It seems like subsequentCOPY
commands could hit the same issue, but in practice they don't for me, so I've just put in the one instance for now.