-
Notifications
You must be signed in to change notification settings - Fork 1
78 lines (63 loc) · 2.6 KB
/
Copy pathci.yml
File metadata and controls
78 lines (63 loc) · 2.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
name: Demos
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: "true"
CMCP_DEV_MODE: "1"
CMCP_BEARER_TOKEN: demo-token
permissions:
contents: read
jobs:
demos:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
submodules: recursive
- name: Set up Python 3.11
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.11"
# requirements.txt is the single source of truth: it already pins both
# cmcp-runtime (demos 1-5) and weight-custody-manifest (demos 6-9).
# Installing cmcp-runtime alone silently left the WCM demos unrunnable.
- name: Install demo dependencies
run: pip install -r requirements.txt
- name: Validate web console examples submodule
run: |
git submodule status --recursive
test -f web-console/vendor/examples/financial-services/catalog.json
test -f web-console/vendor/examples/financial-services/policy/allow.cedar
python -m py_compile web-console/run.py web-console/webserver.py web-console/policy_variants.py
# Static checks first: they need no ports and fail in under a second.
# test_catalog_definition_drift catches a catalog that no longer matches
# its upstream server, which the gateway treats as a rug pull and denies.
- name: Tests
run: |
pip install pytest
python -m pytest tests/ -q
# Run in order: demo-01 produces workspace/trace-claim.json, which
# demo-02 and demo-03 consume.
- name: Demo 1 - cMCP in action
run: python demo-01-cmcp-in-action/run.py
- name: Demo 2 - policy swap
run: python demo-02-policy-swap/run.py
- name: Demo 3 - offline TRACE verification
run: python demo-03-offline-trace/run.py
- name: Demo 4 - context-aware enforcement
run: python demo-04-context-enforcement/run.py
- name: Demo 5 - attribute-based enforcement (BAA coverage)
run: python demo-05-compliance-domain/run.py
# Demos 6-9 are offline: no gateway, no ports, no MCP server.
- name: Demos 6-9 - weight custody
run: |
for d in demo-06-weight-custody demo-07-closed-weight demo-08-derivative-lineage demo-09-sovereign-threshold; do
echo "== $d =="
python "$d/run.py"
done
- name: Demo 10 - governed model calls
run: python demo-10-model-gateway/run.py