Files
sde-meeting-toolkit/CHANGELOG.md
Matt Mabrey 77203955a5 Restrict outbound network to api.anthropic.com only
- New egress-proxy/ container (tinyproxy) that only allows CONNECT to
  api.anthropic.com, refuses everything else.
- docker-compose.yml: sde-meeting-toolkit is no longer on 'default' at
  all. Its only networks are 'proxy' (NPM, inbound) and a new private
  'egress' network shared only with egress-proxy. egress-proxy is the
  only container with a real internet route.
- server.js: route the one outbound Anthropic call through
  EGRESS_PROXY_URL when set, using undici's own fetch + ProxyAgent
  together (mixing them with Node's global fetch throws a version
  mismatch error - caught this locally before it hit a real deploy).
- Add undici as a real dependency (package.json, package-lock.json),
  npm ci step in Dockerfile.
- Add smoke-test-egress.sh + Step 9b in DOCKER_TESTING.md to verify
  this whole chain with real Docker.
- Update CHANGELOG.
2026-09-29 18:16:35 -07:00

10 KiB

Changelog

All notable changes to this project are logged here, newest first. This file starts from the point the toolkit was handed off and set up in this repo.

2026-09-29 (3)

  • Added: outbound network restriction. sde-meeting-toolkit no longer has any direct route to the internet. Its one outbound call (the AI draft button, to api.anthropic.com) is routed through a new egress-proxy container (egress-proxy/, tinyproxy) that only allows that one destination and refuses everything else, even from inside a compromised app container.
  • Added: one real npm dependency, undici (package.json, package-lock.json), and an npm ci step in Dockerfile. Used only to route the Anthropic call through egress-proxy via EGRESS_PROXY_URL. Local, non-Docker runs are unaffected; the app calls Anthropic directly when this isn't set, same as before.
  • Fixed (caught before deploy): Node's global fetch() and an externally-installed undici's ProxyAgent don't mix — throws invalid onRequestStart method, since Node's internal undici and the npm package aren't guaranteed to match versions. server.js now uses undici's own fetch together with its own ProxyAgent for the proxied call, avoiding the mismatch. Confirmed via a local CONNECT-tunnel test.
  • Added: smoke-test-egress.sh, a script that builds the full stack and checks the app container can't reach anything but Anthropic's API, egress-proxy correctly refuses an unrelated domain, and the AI draft button still works end to end. Documented as Step 9b in DOCKER_TESTING.md.
  • Network layout note: sde-meeting-toolkit is on proxy (NPM, inbound) and a new private egress network (to egress-proxy only). egress-proxy is on egress and default (its own internet route). Neither container is on both proxy and default.

2026-09-29 (2)

  • Added: shared login turned on now that the toolkit is reachable at MVP.controls.dev. Username PrimeMVP, password generated and set in .env/Portainer (not committed; .env is gitignored). This is a stopgap ahead of real per-user APP_USERS accounts.
  • Hardened: Dockerfile now runs the container as the built-in non-root node user instead of root, since the app is reachable from the public internet.
  • Hardened: docker-compose.yml drops all Linux capabilities (cap_drop: [ALL]) and disables privilege escalation (security_opt: no-new-privileges:true) on the container.
  • Known follow-up: the ./data folder on the Docker host was created while the container ran as root. After redeploying, it needs chown -R 1000:1000 ./data (or similarly permissive) on the host, or the token quota file and sign-in audit log will silently fail to write under the new non-root user.

2026-09-29

  • Fixed: the AI draft button returned a 502 ("Could not reach the Anthropic API") once the container moved onto the proxy network. Cause: Compose only attaches a container to networks explicitly listed for it, so joining proxy alone dropped the container from the network that had internet access. proxy reaches other containers but not the public internet. docker-compose.yml now lists both proxy and default, so the container keeps its internet route for the outbound call to api.anthropic.com while staying reachable from Nginx Proxy Manager by name.
  • Changed: replaced the plain, unstyled landing page (server.js) with one matching both tools' existing design (dark header bar, IBM Plex Sans, the same card/border/interactive-blue styling), with a short description of each tool and a link into it.
  • Milestone: MVP.controls.dev is live through Nginx Proxy Manager, SSL issued, *.controls.dev already covered by an existing wildcard DNS record (no new DNS record was needed).

2026-09-23

  • Added: joined the toolkit's Docker container to the proxy network, the same shared network Nginx Proxy Manager already uses to reach Work Package Suite's internal nginx container by name. Confirmed by reading NPM's own generated config for wp.controls.dev (/data/nginx/proxy_host/11.conf), which forwards to a container named nginx_webserver, not an IP address. docker-compose.yml now declares proxy as an external network and attaches the container to it.
  • Added: a "Giving it a real address through Nginx Proxy Manager" section in PORTAINER_DEPLOY.md, with the exact NPM Proxy Host settings to point MVP.controls.dev at this container.
  • Decided: the public address for this toolkit will be MVP.controls.dev, a new subdomain, the same pattern as the existing wp.controls.dev. Not a sub-path under Work Package Suite's own domain, to avoid base-path complications in the toolkit's code.

2026-09-04 (2)

  • Added: the two tools now work together. Each tool's header has a link to the other tool. On the Field Problem Workshop, a cluster tagged with a candidate solution (for example "Tracking MVP (pilot)") gets a "Send to Scope Lock" button. Clicking it adds that cluster as a real, unsorted item on the Scope Lock Meeting Suite's Scope Boundary Board. Both tools already share the same browser origin, so this uses a small shared localStorage queue; no backend or database was needed. The item lands on Scope Lock's board the next time that tool is opened or refreshed, and re-sending the same cluster will not create a duplicate. Verified with a jsdom test that simulates both tools sharing one browser's storage.

2026-09-04

  • Fixed: Portainer stack deploy failed with env file /data/compose/44/.env not found. Cause: docker-compose.yml used env_file: - .env, which requires a real file on disk; Portainer's UI-entered environment variables satisfy ${VAR} substitution in the compose file but do not create that file. Changed docker-compose.yml to reference each setting as ${VAR:-default} under environment: instead, which works both for a real local .env (auto-loaded by Compose for substitution) and for values entered directly in Portainer. Corrected the wrong explanation of this in PORTAINER_DEPLOY.md.
  • Changed: renamed the default branch from master to main, both locally and in PORTAINER_DEPLOY.md's repository reference. The old name was just git init's local fallback default, not a deliberate choice.
  • Added: PORTAINER_DEPLOY.md, a step-by-step guide for deploying this as its own stack in Portainer, pulled straight from the Gitea repo, including how to set environment variables through Portainer's UI since .env is not committed.
  • Changed: swapped ANTHROPIC_API_KEY from a personal key to a company-owned key.
  • Milestone: pushed the repo to Gitea at https://primegit.primecontrols-dev.com/m.mabrey/sde-meeting-toolkit.

2026-08-24

  • Changed: enlarged the Breadcrumbs working area. The selected breadcrumb's editor card now has more padding, a taller minimum height, and taller text fields, so it uses more of the page instead of sitting as a small box.
  • Changed: the breadcrumb delete button now reads "Delete" instead of a bare "✕".
  • Fixed: every delete action now shows a confirmation before it deletes. Replaced the browser's plain confirm() popup with a custom on-brand modal (a card with a red left accent, matching the app's existing "attention" styling, on a dimmed backdrop). Covers cluster delete, issue delete, breadcrumb delete, action delete, scope item delete, priority-rank item delete, decision delete, and both Reset buttons. Several of these had no confirmation at all before this change.
  • Fixed: the new breadcrumb list was rendering as single-character vertical columns instead of a normal list. Cause: the list used a <nav> tag, which collided with the app's existing nav{display:flex} rule written for the top tab bar. Changed the element to a <div>.
  • Fixed: the app was capped at max-width:1500px and centered, wasting space on wide screens. Removed the cap so the app fills the browser width.
  • Changed: redesigned the Breadcrumbs panel in the Field Problem Workshop tool. Previously every breadcrumb card showed all 7 fields fully expanded at once, for every breadcrumb, all the time. Replaced with a list-plus-detail split view: a compact status-dot list on the left, the full field editor for one selected breadcrumb on the right.

2026-08-21

  • Added: UNIFIED_TOOL_ROADMAP.md, a design and phased-rollout plan for eventually merging the Field Problem Workshop and the Scope Lock Meeting Suite onto one backend with a shared database. Planning only; not built.
  • Changed: turned the per-user daily token quota off by default (TOKEN_LIMIT_PER_USER=0). A cost analysis against the tool's own baseline usage showed real spend at stake was small enough that the quota wasn't worth the added complexity yet. The code stays in place and can be re-enabled with one setting.
  • Added: a per-user daily token quota (TOKEN_LIMIT_PER_USER), tracked per named user in APP_USERS and persisted to data/token-usage.json, mounted as a Docker volume so usage survives a container restart.
  • Added: MOCK_AI mode. Set MOCK_AI=true to test the AI draft button, the login gate, and the token quota with a canned response, no API key and no cost.

2026-08-20

  • Added: DOCKER_TESTING.md, a step-by-step guide for standing up and testing the Docker environment.
  • Added: a shared login gate (APP_USERS, or legacy APP_USERNAME/APP_PASSWORD) and per-IP rate limiting (RATE_LIMIT_MAX / RATE_LIMIT_WINDOW_MS) ahead of running this for the whole company on the internal network.
  • Added: Dockerfile, .dockerignore, docker-compose.yml to containerize the toolkit, so it can run standalone or alongside the Work Package Suite container.
  • Fixed: the AI draft button returned "Failed to fetch." Cause: it called the Anthropic API directly from the browser with no key, which the browser's CORS policy blocks. Added server.js, a local Node server that serves the two tools and proxies /api/claude to Anthropic server-side, so the API key never reaches the browser. Updated the button in field-problem-workshop.html to call /api/claude instead of api.anthropic.com directly.
  • Added: initial import of the toolkit into this Git repository — README.md, QUICKSTART.md, package.json, .gitignore, the two tool files under tools/, and the breadcrumb-methodology skill under skills/.