The system rejects the request.
Access denied. Policy violation.
The log shows missing authorization.
Security rules are strict and embedded deep.
Open Policy Agent (OPA) is the engine that decides yes or no for every action in your platform. It is policy as code—centralized, fast, and language-agnostic. With OPA, you define rules in Rego, deploy once, and enforce them everywhere. Kubernetes admission control, API authorization, microservice access—OPA handles all of it with consistent logic.
A Minimum Viable Product (MVP) using OPA focuses on integrating the policy decision point into your existing stack without over-engineering. Start with a single, concrete use case. Lock down a sensitive API endpoint. Control resource creation in Kubernetes based on labels. Limit database queries to approved patterns. Each policy is a Rego file stored in source control, versioned alongside your code, tested like any other unit or integration test.
OPA runs as a sidecar, daemon, or embedded library. The choice depends on your architecture. For a containerized deployment, a sidecar is the fastest way to ship. Your service sends structured JSON to OPA, gets a decision back in milliseconds. No external calls to slow you down if you run it locally. When scaling, use service discovery or a small cluster of OPA instances behind a load balancer.