mirror of
https://github.com/open-policy-agent/opa.git
synced 2026-08-13 03:42:35 -06:00
38a988765d
These changes add support for accessing runtime information inside of policies. In some cases, policies need to access environment variables or configuration that OPA was booted with. These changes add a built-in function that allows policies to gain access to this information. The built-in function itself is relatively trivial. Most of the required changes were plumbing the runtime information from the entrypoint down into the evaluation engine. The alternative would have been to introduce a global variable containing this information however that would be have been harder to reason about in library integrations. Fixes #420 Signed-off-by: Torin Sandall <torinsandall@gmail.com>