Skip to content

Commit 8d6dc7a

Browse files
authored
Merge pull request #1491 from tedhabeck/opa-updates
Opa updates
2 parents bde5eca + b7abe12 commit 8d6dc7a

File tree

4 files changed

+18
-4
lines changed

4 files changed

+18
-4
lines changed

plugins/external/opa/.env.template

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44

55
# Enable the plugin framework
66
PLUGINS_ENABLED=false
7-
7+
# default host port to listen on
8+
PLUGINS_SERVER_HOST=0.0.0.0
89
# Enable auto-completion for plugins CLI
910
PLUGINS_CLI_COMPLETION=false
1011

@@ -22,5 +23,6 @@ PLUGINS_CONFIG=./resources/plugins/config.yaml
2223
# Configuration path for chuck mcp runtime
2324
CHUK_MCP_CONFIG_PATH=./resources/runtime/config.yaml
2425

26+
PLUGINS_TRANSPORT=streamablehttp
2527
# Path to the repo policy file (optional, default: ./opaserver/rego/policy.rego)
2628
# POLICY_PATH=./opaserver/rego/policy.rego

plugins/external/opa/Containerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ ARG SKILLS_SDK_COMMIT_ID
1111
ARG SKILLS_SDK_VERSION
1212
ARG BUILD_TIME_SKILLS_INSTALL
1313

14-
ARG OPASERVER_VERSION=1.8.0
14+
ARG OPASERVER_VERSION=1.10.1
1515
ARG TARGETARCH
1616

1717
ENV APP_HOME=/app

plugins/external/opa/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ SHELL := /bin/bash
88
PACKAGE_NAME = opapluginfilter
99
PROJECT_NAME = opapluginfilter
1010
TARGET ?= opapluginfilter
11-
OPASERVER_VERSION ?= 1.8.0
11+
OPASERVER_VERSION ?= 1.10.1
1212
POLICY_PATH = "./opaserver/rego/policy.rego"
1313

1414
# Virtual-environment variables

plugins/external/opa/README.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ The OPA plugin and loader configuration can be customized in `resources/plugins/
4040

4141
## Installation
4242

43-
1. In the folder `external/opa`, copy .env.example .env
43+
1. In the folder `external/opa`, copy .env.template .env
4444
2. Add the plugin configuration to `plugins/external/opa/resources/plugins/config.yaml`:
4545

4646
```yaml
@@ -173,6 +173,18 @@ starting
173173

174174
## Testing with gateway
175175

176+
### Authentication & Tokens
177+
Run the following from the project root folder:
178+
179+
```bash
180+
# Generate JWT bearer token
181+
python3 -m mcpgateway.utils.create_jwt_token --username [email protected] --exp 10080 --secret my-test-key
182+
183+
# Export for API calls
184+
export MCPGATEWAY_BEARER_TOKEN=$(python3 -m mcpgateway.utils.create_jwt_token --username [email protected] --exp 0 --secret my-test-key)
185+
```
186+
187+
176188
1. Add server fast-time that exposes git tools in the mcp gateway
177189
```bash
178190
curl -s -X POST -H "Authorization: Bearer $MCPGATEWAY_BEARER_TOKEN" \

0 commit comments

Comments
 (0)