Skip to main content

Open Policy Agent (opa)

Policy decision point of every Navin Enterprise gateway (models, tools, MCP, data). Loads the Navin policy bundle and answers the decisions of the Control Plane.

Generated from catalog/services/opa.yaml: do not edit by hand.

Summary​

Version1.21.4
Useinstall and configure, configure and connect
Layerfunctional (AI catalog)
CategorySecurity and policies
Installation methodsbinary, podman
External connectionno
Sandbox onlyno

Licence​

SPDX identifierApache-2.0
Licence policycore licence (MIT or Apache-2.0)
Licence exception-
Platform componentopa

Packages and artifacts​

A package the project of the service publishes (its image, its binary archive, its Python or OS package) carries the licence of the service; a third-party package carries the licence written on its row, read from the official upstream metadata.

KindPackageVersionLicenceDetails
container imagedocker.io/openpolicyagent/opa1.21.4-staticApache-2.0image key opa, used by opa-server, digest sha256:47f93480b09e24c220ae75f1e9133585ba6d698059951668d35e6a4fc32ebc82
binary archiveopa1.21.4Apache-2.0https://github.com/open-policy-agent/opa/releases/download/v1.21.4/opa_linux_amd64_static, x86_64, checksum sha256

Images are pinned by tag in the descriptor, and by digest when the descriptor declares one (the offline bundle then refuses a pulled image that does not carry it); the digest is recorded in the mirror of the Manager when the offline bundle is imported, and every pull or load is checked against it.

Supported systems and architectures​

MethodOperating systemsArchitectures
binaryRHEL family (dnf), Debian family (apt), Arch Linux (pacman)x86_64 (architecture of the artifacts of the descriptor)
podmanRHEL family (dnf), Debian family (apt), Arch Linux (pacman)x86_64, aarch64 (not restricted by the descriptor)

Certified host systems: RHEL 8/9/10, Rocky Linux 8/9/10, AlmaLinux 8/9/10, Oracle Linux 8/9, CentOS Stream 9/10, Ubuntu 22.04/24.04, Debian 12, Arch Linux (rolling). The host preflight accepts these systems (other releases of a known family give a warning, end of life releases are refused) and the x86_64 and aarch64 architectures.

Prerequisites​

Host​

  • at least 512 MB of memory (blocking, memory).

Network and ports​

ComponentPort namePortOpened in the host firewall
opa-serverapi8181/tcpyes
opa-serverdiagnostic8282/tcpyes

Services and connections needed​

This service has no dependency.

Installation methods and modes​

MethodDefaultWhat the method uses
binaryyesthe binary archives of the descriptor, unpacked under the service directory
podman-the container images of the descriptor, run by Podman under systemd

Components​

ComponentKindInstallation methodsPorts
OPA server (opa-server)masterbinary, podman8181/tcp, 8282/tcp

Single server (standalone) (default)​

One OPA server, for a sandbox or a small installation.

What the mode deploys:

ComponentPlacement
opa-servermin 1, max 1

Replicated (replicated)​

Several stateless OPA servers behind the load balancer; each loads the same bundle.

What the mode deploys:

ComponentPlacement
opa-servermin 2, recommended 3

Install this service​

The install wizard of the Navin Manager plans, validates and runs the installation; you need the services:install permission on the cluster.

  1. Open the wizard. In Clusters, choose the row action Install services of the target cluster. The wizard opens on its first step, Service.

  2. Choose the service. On the Service step, select Open Policy Agent. The card shows the licence Apache-2.0. Pick the Method among binary, podman (default binary).

  3. Choose the hosts and the mode. On the Hosts step, tick the hosts, then choose the Mode: standalone (default), replicated. Each mode deploys the components listed in Installation methods and modes.

  4. Bindings. This service has no dependency: the Bindings step has nothing to bind.

  5. Configure. On the Configure step, review the parameters (see Configuration parameters). Passwords left empty with a generated default are generated and sealed by the Manager.

  6. Review and install. On the Install step the Manager validates the plan and shows the installation order; when it says "The plan is valid. Ready to install.", choose Install. A highly available mode is installed only when its HA checks pass.

  7. Verify. The operation ends when the health checks of every instance pass (see Health checks); the service then shows as running in Services. Open the service and choose Run the smoke test in the Checks card: Loads a policy, asks a decision that must allow and one that must deny, then removes the policy.

Connect an existing service​

Schemeshttps, http
Default port8181
Authenticationoptional
Health check/health
Authentication methodFieldsDescription
bearertokenOPA started with --authentication=token and --authorization=basic: system.authz must let the token read /v1/policies.
client_certificateclient_cert, client_keyOPA started with --authentication=tls: client certificate signed by the authority of --tls-ca-cert-file.
none-Default of OPA: no authentication, bind it to a filtered network.

Official documentation: https://www.openpolicyagent.org/docs/security

High availability​

Clusterreplicas (replication)
High availabilityexternal (external)
Failoverload balancer (load-balancer)
Replicationshared store (shared-store)
Quorumnone (none)
Discoverynone (none)
Entry pointload balancer (load-balancer)
Official documentationhttps://www.openpolicyagent.org/docs/deploy
Peer TLS parametertls_enabled

Topology per mode​

ModesHighest catalog levelDistributionQuorum componentFault domainsDescription
standalonestandalone (standalone)single (single)-1One instance, no fault tolerance.
replicatedha (ha)active-active (active-active)-2Several stateless servers behind the load balancer, each loading the same policy bundle.

Notes​

  • Every instance evaluates on its own copy of the policies: with bundles enabled the bundle server must stay reachable for updates, the last loaded bundle keeps serving meanwhile.

Configuration parameters​

Network​

ParameterTypeDefaultAllowed valuesRequiredSecretRestartDescription
API port (port)port8181-nononoPort of the decision API (/v1/data).
Diagnostic port (diagnostic_port)port8282-nononoPort of /health and /metrics, kept apart from the decision API.
TLS (tls_enabled)boolfalse-nononoServe the API over TLS with a certificate issued by the manager CA.

Policy bundle​

ParameterTypeDefaultAllowed valuesRequiredSecretRestartDescription
Bundle server (bundle_url)url{{ mirror.url }}/bundles-nononoBase URL serving the policy bundle.
Bundle file (bundle_resource)stringnavin-policies.tar.gz-nononoPath of the bundle below the bundle server.
Load the bundle (bundle_enabled)booltrue-nononoDownload and activate the Navin policy bundle (disable only to test the empty server).
Minimum polling delay (bundle_min_delay_s)int30min 5, max 3600nonoyesSeconds between two bundle downloads (minimum). (advanced)
Maximum polling delay (bundle_max_delay_s)int120min 10, max 7200nononoSeconds between two bundle downloads (maximum). (advanced)

Logging​

ParameterTypeDefaultAllowed valuesRequiredSecretRestartDescription
Log level (log_level)enuminfodebug, info, warn, errornononoVerbosity of the server log.
Decision logs (decision_logs_console)booltrue-nononoWrite every decision to the journal (collected by the log pipeline for the SIEM).

Endpoints​

EndpointSchemeComponentPortPathTLS parameterBinding parametersBinding secretsProvisioning command
apihttpopa-server8181 (port)-tls_enabled---

Client configuration files​

Files rendered for the client configuration download:

  • opa.env (client.env.j2)

Commands​

CommandComponentTargetDescription
Check the policy bundle (bundle_status)opa-serverevery hostAsks every OPA server whether the Navin bundle is activated.

Health checks​

Liveness (per instance)​

ComponentCheckDetails
opa-serverHTTP {{ 'https' if config.tls_enabled else 'http' }}://{{ host.fqdn if config.tls_enabled else (host.ip or '127.0.0.1') }}:{{ config.diagnostic_port }}/healthExpected 200; 30 retries; interval 1 s; timeout 3 s

Readiness (service check)​

CheckDetails
HTTP {{ 'https' if config.tls_enabled else 'http' }}://{{ host.fqdn if config.tls_enabled else (host.ip or '127.0.0.1') }}:{{ config.port }}/v1/data/system/mainExpected 200, 404; 5 retries; interval 2 s; timeout 5 s

Smoke test​

Loads a policy, asks a decision that must allow and one that must deny, then removes the policy. (opa-server: load_policy, decision_allow, decision_deny, remove_policy)

Preflight checks​

CheckTypeMeaningSeverityComponents
memorymemory_mb {"min": 512}at least 512 MB of memoryblockingevery component
api_port_freeport_free {"param": "port"}port 8181 free on the hostblockingevery component

Upgrade​

Supported from1.21.3
Statefulno
Backup before the upgradeno
Rollbackyes

Uninstall​

Paths removed when the data is purged: {{ paths.data }}, {{ paths.log }}.

  • Diagnostic metrics: {{ 'https' if config.tls_enabled else 'http' }}://{{ host.fqdn }}:{{ config.diagnostic_port }}/metrics

Upstream documentation​