liveBook · Manning

Rego

Rego is a declarative query and policy language for expressing rules over structured data, commonly evaluated by Open Policy Agent and related systems.

How 2 Manning books explain it

Effective Platform Engineering

Rego is a declarative policy language used by Open Policy Agent to evaluate structured input against authorization and other rules.

How it is used
Enforces shared governance requirements at deployment boundaries without requiring central ownership of development teams’ pipelines.
How deep it goes
Explains declarative predicates and JSON-based decisions through policies and deployment inputs, while leaving agent deployment and policy publishing details aside.
Examples
Uses an age-based allow rule, deployment coverage checks, and an exercise restricting container images to an organization’s registry.
What you can do after
Build it from scratch: write a Rego admission policy that checks deployment data against a coverage or container-registry requirement.

Read how Effective Platform Engineering explains Rego →

Authorization in Action

Rego is a declarative policy language used to express rules evaluated by policy engines such as Open Policy Agent.

How it is used
Uses Rego with OPA for authorization and infrastructure decisions across distributed systems.
How deep it goes
Explains rule conditions and PARC input modeling through examples, then compares Rego’s manual scope with Cedar’s structural scope.
Examples
Illustrates confidential-document access by department and restricts a delete action to admin-group members.
What you can do after
Evaluate and understand Rego’s fit for infrastructure policy, including its flexibility, manual scoping, and maintenance tradeoffs.

Read how Authorization in Action explains Rego →

Also covered in

What to know first

Related concepts

Questions about Rego

What is Rego?

Rego is a declarative query and policy language for expressing rules over structured data, commonly evaluated by Open Policy Agent and related systems.

Which Manning books explain Rego?

Effective Platform Engineering and Authorization in Action.

What should I know before learning Rego?

Manning books that teach Rego usually introduce JSON and policy first.

What is the difference between Rego and scope?

Rego is a declarative query and policy language for expressing rules over structured data, commonly evaluated by Open Policy Agent and related systems. Scope is a defined boundary that determines what entities, activities, resources, or conditions are included, governed, or permitted in a particular context.

What is Rego a kind of?

Rego is a kind of policy language. A policy language is a formal language for expressing rules governing permissions, actions, authorization, or resource access.

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.