You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes it is useful to update runtime config in server runtime using name. Currently, it is only possible by mapping environment variables with the same (and known names)
Example:
// server/plugins/runtime-config.tsexportdefaultdefineNitroPlugin(()=>{constconfigOverrides={foo: {bar: "baz"}};// load from any sourceupdateRuntimeConfig(configOverrides);// any code in any file after this line will be affected})
Discussion:
We should choose between two orders: (low to high):
bundled vars > programmatic overrides > environment variable
bundled vars > environment variable > programmatic overrides
2 makes sense in the way that manual updateRuntimeConfig is more explicit than implicit environment variables (more making sense in testing scenarios) but it also breaks 12 factor and can cause headaches for sys admins not being able to quickly control instance behavior.
I am thinking of using order 1 but allowing a way to opt out from the environment variable support (testing environments in case there is a chance of conflict)
The text was updated successfully, but these errors were encountered:
Context: #2404 (comment)
Sometimes it is useful to update runtime config in server runtime using name. Currently, it is only possible by mapping environment variables with the same (and known names)
Example:
Discussion:
We should choose between two orders: (low to high):
2 makes sense in the way that manual
updateRuntimeConfig
is more explicit than implicit environment variables (more making sense in testing scenarios) but it also breaks 12 factor and can cause headaches for sys admins not being able to quickly control instance behavior.I am thinking of using order 1 but allowing a way to opt out from the environment variable support (testing environments in case there is a chance of conflict)
The text was updated successfully, but these errors were encountered: