https://pulumi.com logo
#general
Title
# general
c

chilly-hairdresser-56259

04/20/2021, 3:03 PM
Does anyone know if you can create your own custom tags in the Docker Provider? If you set
ImageName = blah:1
it appears that Pulumi appends a dynamic hash. Is there a way to override?
l

loud-helicopter-75345

04/20/2021, 3:33 PM
That hash thing you are talking about sound a lot like in the Kubernetes module, when you name the Pulumi resource but don't pass a name in the ResourceArgs metadata. It then uses the resource name, but appends a hash so that there are no collisions with other existing resources. Can you share some of the code?
c

chilly-hairdresser-56259

04/20/2021, 3:49 PM
The reason why I want to override that hash, is so I can do predictable updates to my ECS resources. Currently the Pulumi.Docker BuildImage when it hit a different host produces different hashes thus causing a ContainerDefinition change everytime. My workaround is to produce a hash of the built artifact and then pull that in for the Image. So that the hash either changes or doesn't change based on the compiled language
@loud-helicopter-75345 I was looking for ResourceArg
Name
/
Tag
that way I can statically set the Tag to my custom hash.
Actually upon the push it does append, but also tags your resource with two tags. So it will work
👍 1
l

loud-helicopter-75345

04/21/2021, 11:13 AM
Glad you figured it out. Sorry got distracted as the PulumiUP event had started
👍 1
c

chilly-hairdresser-56259

04/22/2021, 2:10 PM
Yea been watching that, pretty cool things going on!