Practice advanced OPA and Rego vocabulary: policy evaluation, data documents, partial evaluation, conftest unit testing, and OCI-based policy bundle distribution.
0 / 5 completed
1 / 5
'The Rego policy evaluates to ___.' Which word describes a blocking policy decision?
In OPA/Rego, policies evaluate to 'deny' (or 'allow'). A 'deny' decision means the policy violation was detected and the admission controller or authorization layer should block the action.
2 / 5
'The policy uses ___ documents.' Which noun describes external reference data in OPA?
OPA 'data documents' are external reference data loaded into OPA alongside policies — e.g., allowed registries, approved namespaces, or cost tags. Policies can query data documents to make decisions.
3 / 5
What is 'partial evaluation' in OPA?
Partial evaluation in OPA evaluates policy rules against known static data ahead of time, producing a simplified residual policy. This dramatically speeds up runtime evaluation by reducing repeated computation.
4 / 5
'We unit test policies with ___.' Which tool is designed for testing OPA policies?
Conftest is a tool for writing tests against structured configuration (YAML, JSON, Terraform) using OPA/Rego policies. It integrates easily into CI pipelines for policy testing.
5 / 5
'The policy bundle is distributed via ___ registry.' Which standard is used for distributing OPA bundles?
OPA bundles (collections of policies and data) can be distributed via OCI (Open Container Initiative) registries — the same registries used for Docker images. This simplifies distribution and versioning.