He folks, I am new to Pulumi and am having trouble...
# dotnet
He folks, I am new to Pulumi and am having trouble with some configuration management. I am trying to read config vaules from the stack yaml file (some of which are secrets) and inject them into a IConfigurationSource implementation to allow for IOptions support. The issue I am facing is I am unable to access the actual string values of the Output returned from the
calls. I saw mention in the docs and a reply to another thread to use the
method to unwrap the values but the return values from all options for the
method return `Output`s. I am using the latest versions available from NuGet: • Pulumi v3.56.2 • Pulumi.AzureNative v2.6.0 Does anyone have advice on how to solve this issue?
You cannot get a standard string from an output. You need to do it inside the Apply
Thanks @billowy-army-68599, appreciate your time
If you share some code we can likely get it working
I think I was over thinking it tbh, have been refactoring a bunch of code and have stumbled upon a solution. Weird how new stuff can trip you up on seemingly simple things 😄
@bright-hydrogen-2039 if you haven't already seen this example, it has some neat stuff https://github.com/gitfool/Pulumi.Dungeon
I've never seen Pulumi Dungeon before! The readme is rather thin; what's the repo's purpose?
I believe the creator uses it at his place of employment but made it OS which is nice. It's a great example of Pulumi/C#/automation-api. It uses multiple providers, AWS and the k8 provider. Config happens via yaml files which he made inheritable, kind of neat. But config could happen from any provider. The end result is it standing up an EKS cluster and then uses the K8 provider to further configure it. But the overall example could be used to provision anything.
It also uses Scriban to for config/policy templating.