:wave: hello! qq: what’s the recommended approach...
# general
m
👋 hello! qq: what’s the recommended approach of reading a secret from another project? context: my project
infra
exports a
kubeconfig
for a kubernetes cluster (and it’s a secret), and my project
services
reads it, creates a
k8s.Provider
and uses that to provision my services in the cluster. I cannot use
StackReference.getOutputValue()
because the output is a secret. If I use
StackReference.getOutput()
, then I have to do
Output.apply()
to transform it into a
Output<k8s.Provider>
. But the k8s resources only takes `k8s.Provider`s, not `Output<k8s.Provider>`s… so.. I guess one option is to put everything inside the
apply()
call.. but that’s undesirable. I’m wondering if there’s a cleaner way
p
You should be able to give the resulting output of
getOutput
as a parameter to the k8s.providers'
kubeconfig
👀 1
m
thanks! 🙏 that works for me 👍