breezy-cricket-40277
12/03/2020, 9:54 AM@pulumi/random
and then I have my own method to generate an hash out of it, then base64
encode to put in a k8s secret. My question is, how can I make sure that my hash
method is only called if the RandomPassword
changes?GenerateHashedPassword
is my method that returns a string
with the hash.preview
or up
the GeneratedHashedPassword
method gets called and generates a different hash.. so all the dependencies that I have on that also get regenerated 😕pulumi
way of handling this, or do I have to change my underlying method to always return the same output given one input?brave-planet-10645
12/03/2020, 10:04 AMbreezy-cricket-40277
12/03/2020, 10:27 AMrandomPassword
doesn’t change, pulumi doesn’t run my function.
Just tried it and it works fine.
Thank you @brave-planet-10645 👍brave-planet-10645
12/03/2020, 10:38 AMbreezy-cricket-40277
12/03/2020, 10:38 AMtraefik
v2 basic auth btw.
Then on the secret, I just call this method with the desired user
.
Ofc, can be adapted for multiple users.billowy-army-68599
stringData
to a Kubernetes secret (instead of data
) and the k8s API will base64 encode it:
always useful to knowwet-soccer-72485
12/03/2020, 10:27 PM