Hi folks, I'm trying to pull a docker image from a...
# aws
s
Hi folks, I'm trying to pull a docker image from a private repo and push it to AWS ECR, I tried awsx.ecr.Image and docker.Image with right ecr registry info set. But they build the image and then push it, is there a way to skip the build and just push the local image available?
m
Are you asking about the additional time it takes to build the image for to do the diff?
s
in my build setup I build the images and upload them to dockerhub, now I want pulumi to just pull and upload this image to ECR without building the image locally again Related issue: https://github.com/pulumi/pulumi-docker/issues/54
docker.Image() builds image locally, which I want to avoid
m
s
Isn't that for buildcache? I want to avoid the build altogether I want to do this 1. docker pull <soucre> 2. docker tage <source> <ecr-dest> 3. docker push <ecr-dest> I can't find equivalent for 3
m
I don't think you can currently achieve what you want with the provider
s
Ah that's sad, so a work around is to use
command
and run docker commands like mentioned in the issue. Do you know any other work around?
m
I was suggesting the build cache as a work-around, unfortunately. Command can work, or maybe look into something with https://www.pulumi.com/registry/packages/docker/api-docs/getregistryimage/ (I don't have any personal experience with this, though)
s
I'll check that, Thanks!!
m
Good luck, I'm curious about what solution you end up going with.