opa eval

Evaluate a Rego query

Options

NameDescription
--bundle, -b <bundle>Set bundle file(s) or directory path(s). This flag can be repeated
--capabilities <capabilities>Set capabilities.json file path
--count <count>Number of times to repeat each benchmark
--coverageReport coverage
--data, -d <data>Set policy or data file(s). This flag can be repeated
--disable-early-exitDisable 'early exit' optimizations
--disable-indexingDisable indexing optimizations
--disable-inlining <disable-inlining>
  • Repeatable ♾
--explain <explain>Enable query explanations
--failExits with non-zero exit code on undefined/empty result and errors
--fail-definedExits with non-zero exit code on defined/non-empty result and errors
--format, -f <format>Set output format
--ignore <ignore>Set file and directory names to ignore during loading (e.g., '.*' excludes hidden files)
--import <import>Set query import(s). This flag can be repeated
--input, -i <input>Set input file path
--instrumentEnable query instrumentation metrics (implies --metrics)
--metricsReport query performance metrics
--package <package>Set query package
--partial, -pPerform partial evaluation
--pretty-limit <pretty-limit>Set limit after which pretty output gets truncated
--profilePerform expression profiling
--profile-limit <profile-limit>Set number of profiling results to show
--profile-sort <profile-sort>Set sort order of expression profiler results
--schema, -s <schema>Set schema file path or directory path
--shallow-inliningDisable inlining of rules that depend on unknowns
--stdinRead query from stdin
--stdin-input, -IRead input document from stdin
--strict-builtin-errorsTreat built-in function errors as fatal
--target, -t <target>Set the runtime to exercise
--timeout <timeout>Set eval timeout (default unlimited)
--unknowns, -u <unknowns>
  • Repeatable ♾
--help, -hHelp for eval