Rego is the declarative policy language used by Open Policy Agent (OPA). This tile covers writing and testing Rego policies for Kubernetes admission control, Terraform and infrastructure-as-code plan validation, Docker container authorization, HTTP API authorization, RBAC and role-based access control, data filtering, metadata annotations with opa inspect, and OPA policy testing with opa test.
99
Quality
Pending
Does it follow best practices?
Impact
99%
1.19xAverage score across 31 eval scenarios
Pending
The risk profile of this skill
This tile teaches AI agents how to write correct, idiomatic Rego policies using Open Policy Agent (OPA). It covers the full range of OPA use cases and enforces best practices through steering rules and curated reference documentation.
Policy domains covered:
ConstraintTemplate policiesopa-docker-authzopa test, mocking with with, parameterised tests# METADATA blocks, entrypoints, severity classification, opa inspectKey patterns enforced:
import rego.v1 and OPA 1.0 syntax (if, contains, some...in, every)tfplan := object.get(input, "plan", input) for HCP Terraform compatibilitydeny contains msg if { ... }object.get for safe field access with defaultscreate and update actions in IaC policies