bdjgs
09/10/2025, 7:32 AMAsk Inkeep
09/10/2025, 7:32 AMAsk Inkeep
09/10/2025, 7:32 AMOPAL_BROADCAST_URI environment variable, for example: (2)
export OPAL_BROADCAST_URI=postgres://postgres:postgres@localhost:5432/postgres
Multiple Git Repositories for a Single OPAL Client
You're correct that there are limitations here. Each scope contains its own policy and data sources from a single Git repository. (3) An OPAL client subscribes to specific directories within a policy repository, but this is within a single tracked branch of one repository. (4)
However, there are alternative approaches mentioned in the documentation:
1. *OPAL Scopes*: While each scope is associated with a single Git repo, you can use scopes to serve different policies to different clients. (3) (5) This is described as "a classic setup for larger deployments, allowing each service to have its dedicated OPAL Client, with its OPA and Policy Repo, managed independently by the relevant team." (5)
2. *Git Submodules*: According to a GitHub discussion, OPAL doesn't currently support Git submodules for pulling multiple repos into one. The submodules would appear as empty folders.
The recommended approach for multiple policy repositories is to use OPAL Scopes with separate clients for each repository, rather than having a single client pull from multiple repositories.Ask Inkeep
09/10/2025, 7:33 AMAlon Boshi
09/10/2025, 7:34 AMbdjgs
09/10/2025, 7:38 AMopal_server_1 | 2025-09-10 07:37:07.458 | DEBUG | opal_server.redis_utils:__init__:13 - Connecting to Redis
And for the second question, it seems to agree, that it is not possible to make the OPAL client fetch policies from multiple Git repos and provide them all to the interal OPA.Dan
09/10/2025, 7:53 AMbdjgs
09/10/2025, 7:56 AMbdjgs
09/11/2025, 7:29 AMDan
09/11/2025, 6:07 PMbdjgs
09/12/2025, 7:09 AMOr Weis
09/12/2025, 7:14 AMOr Weis
09/12/2025, 7:18 AMbdjgs
09/12/2025, 7:25 AMOr Weis
09/12/2025, 7:27 AM