-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AWS Private ECR Pull, Build, Push - not pulling in CI #566
Comments
hi @ShedPlant - thank you for filing this issue. To answer your first question: you should not need to pull anything using RemoteImage, especially given that your. code works locally as expected 👍 . This does bring up the difficulty in reproducing this bug, because we do not know how your CI is set up, and this could be an authentication issue. However, we did in fact fix a few issues around inline cacheing in #537, so we would encourage you to give v4.1.0 a try! |
I've upgraded from To clarify, this isn't just a CI only problem, I see the same locally. On first build:
Expected behaviour:
Actual behaviour:
Remove that single line code change and run Of course, in CI, the environment is freshly created each time so it's always the first run. |
If I pull the docker image manually as a prior step, the docker build caches as expected:
|
Btw I'm not alleging it worked differently in v3. Maybe this is a feature request, or how it's supposed to work 🤷 . My use case is I want my builds to happen as fast as possible. I realise that caching |
I'm also seeing this when using Could it have something to do with this? aws/containers-roadmap#876 From the resource description
Side note: these details are missing from the official docs https://www.pulumi.com/registry/packages/docker/api-docs/image/#cachefrom |
Thank you for the link @DominicRoyStang. ❤️ @ShedPlant - in order for us to help you out better, since this runs in Actions, can you please give us a link to a minimal repro in a github repository? We, too, would like everyone's builds to be as fast as possible. |
https://github.com/curoo/pulumi-docker-investigations/tree/master/issues/issue_566
|
What happened?
I have:
Dockerfile
, takes 5-10m to build from scratchI upgraded to
pulumi-docker
4.0.0
because I saw it enables Buildkit by default and I was hoping it would fix my caching problem 😁 .But in the GHA CI, even though v4 seems to be quicker than v3, the build still always takes a few minutes and I can see logs (thanks for improved logging!) showing it's compiling. I expected that the 2nd time CI ran, this would be cached.
On my local machine, running
pulumi up
a second time is very quick to build the image 👍 .I think the image isn't being pulled first in CI.
I see
resolve docker.io/amazon/aws-lambda-python:3.9@sha256:96385e8762b8ef280957fdc33963f18a6af3b38a61530dc5b58ffd0e46afbb3d
but not anything about pulling the
my_app
.Do I have to do the pull explicitly first with
RemoteImage
? I tried this but it wasn't obvious how to make that work with a private ECR 😕 .Am I doing it wrong 🙂 ?
Expected Behavior
I want:
Steps to reproduce
My
Dockerfile
looks something like:My pulumi resource looks something like:
Output of
pulumi about
I don't want to copy/paste this from a work project. I'll try to provide specific info as requested if relevant.
Additional context
No response
Contributing
Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).
The text was updated successfully, but these errors were encountered: