openshift / console-plugin-template

Minimal template for writing OpenShift console plugins
Apache License 2.0
37 stars 47 forks source link

Use ENVs during Runtime on OpenShift #70

Closed sambou90 closed 2 weeks ago

sambou90 commented 2 weeks ago

Hi there

I want to use ENVs during Runtime on OpenShift. At first sight I could not place a runtime-config.json on the Webserver which serves the Plugin.

Does anyone have experience with this and can place a hint?

Thanks and regards

spadgett commented 2 weeks ago

Hi, @sambou90. Do you simply want to load a JSON file with the configuration from your plugin's webserver? I believe you should be able to make a request using consoleFetch to the endpoint /api/plugins/<plugin-name>/path/to/runtime-config.json.

cc @jhadvig @vojtechszocs

sambou90 commented 2 weeks ago

Hi @spadgett Very nice that works fine! Thank you for your quick response!