Hi, I've got an odd question and maybe there's a m...
# general
Hi, I've got an odd question and maybe there's a much better way to do this. Essentially I'm trying to implement a different comparison for my ECS service's task definition in golang. Our Docker build process produces images with different IDs even when the base image and the service we're running in the image have not changed. This causes Pulumi to always create a new task definition during deployments. We want to avoid this so I was looking into computing the hash of the image inputs (base image and service executable) and comparing that to the hashes of the currently deployed image. If they are the same, I want the task definition to use the same Docker image ID instead of the new one. To accomplish this I need to store those hashes and, ideally, I'd like to store them in the state file. I've tried adding them as outputs on my component resource that encapsulates all the ECS resources but I can't find a way to read those values at runtime of the pulumi program. I tried using
but this requires my component resource to embed
instead of
and when calling
it produces an error stating there isn't a plugin for the namespace I'm using for my component resource. So, finally, to my question, is there a way to read the outputs of a component resource inside a pulumi program without just parsing the state file directly?