How to read configMap from cluster and use those values to create the component? #6384
Replies: 5 comments 3 replies
-
I could read a cluster configMap and pass this information using the read-object operation. However, the aim is to make this information available to all components/traits. So it would have to be something more generic. It's like injecting a context from the cluster like: aws-account-id, stack-id, etc. |
Beta Was this translation helpful? Give feedback.
-
c/c @chivalryq sorry to mention you, but could you help here, please? |
Beta Was this translation helpful? Give feedback.
-
Hi, you can checkout this doc, note that the action is only valid in workflowsteps. |
Beta Was this translation helpful? Give feedback.
-
Thanks for your reply. I want to make the application as simple as possible for end users. In the suggestion you commented, is it possible to create a custom workflowstep that reads an existing configMap using op.#Read and uses op.ws.#DoVar to add the configMap data in the context? Therefore, it is possible to use the configMap data in the custom component using the context variable |
Beta Was this translation helpful? Give feedback.
-
If I might add to this discussion, was looking for a similar solution as we're starting to adopt KubeVela at my company. |
Beta Was this translation helpful? Give feedback.
-
Hi! I would like to create a component using values from configMap inside the cluster. How can I do it?.
is the only way using workflow-step?
Beta Was this translation helpful? Give feedback.
All reactions