NSC Labs
Practical README

Copr Gateway

Last updated: 2026-07-09

copr_gateway is a bounded per-executable runner behind a small HTTP gateway. It is designed for one file, one run, explicit status, and clean handoff to April-side observation and message packaging.

Status: Private distribution

Go + Rust Per executable Explicit run boundary April stack separate

License summary

copr_gateway is licensed, not sold.

The license covers the purchasing customer and its affiliates under common control.

Service providers may operate the software on the customer’s behalf, but do not receive independent license rights.

copr_gateway may be used in the customer group’s business operations, including internet-facing deployments and customer-serving systems.

copr_gateway itself may not be resold, sublicensed, or transferred as a standalone product without written permission.

Purchase or subscription does not guarantee future updates, upgrades, downgrades, bug-fix releases, support, or continued development unless expressly stated in the applicable order, Marketplace offer, or Seller support policy.

Optional operational surfaces may be offered separately from time to time. If an optional capability is offered for a separate fee, it is included only when expressly covered by the applicable order, Marketplace offer, or Seller support policy.

Use of copr_gateway is governed by the applicable order and the EULA.

What it is

Per-executable run

Small HTTP surface over a bounded runner for one explicitly supplied executable file at a time.

Run boundary

Reports the run boundary clearly so outside tooling can observe logs, stderr, and surrounding evidence.

Small status

Returns explicit status without becoming an orchestrator, container-control layer, or April observation stack.

What it does

April may call Copr, but April, bea-series observers, Milky receipts, Hammer packaging, and LLM-facing message packaging stay outside Copr.

Deployment model

copr_gateway is intended to expose a small runner package.

The important unit is the executable file run, not a broad container-control surface.

Default runtime configuration:

Environment variables:

Quick start

Build the package image:

docker build -f nsc_mai/crates/copr_gateway/Dockerfile -t copr_gateway:2026.1.0 .

Run it:

docker run --rm \
  -p 8080:8080 \
  -v $(pwd)/data:/data \
  -e COPR_BIND_ADDR=:8080 \
  -e COPR_API_BIN=/usr/local/bin/copr_api \
  -e COPR_RUN_ROOT=/data/runs \
  -e COPR_STATUS_THIN=true \
  copr_gateway:2026.1.0

API overview

GET /health

Minimal liveness check.

{"ok":true}

GET /status

Returns compact gateway status.

The status surface is intentionally small by default.

POST /run

Request a bounded executable run.

{"file":"/work/example.exe","args":[]}

POST /run/status

Inspect a run boundary by id.

{"run_id":"example-run"}

POST /run/close

Close the run boundary explicitly.

{"run_id":"example-run"}

Example calls

curl -s http://127.0.0.1:8080/health
curl -s http://127.0.0.1:8080/status
curl -s -X POST http://127.0.0.1:8080/run \
  -H 'Content-Type: application/json' \
  -d '{"file":"/work/example.exe","args":[]}'
curl -s -X POST http://127.0.0.1:8080/run/status \
  -H 'Content-Type: application/json' \
  -d '{"run_id":"example-run"}'
curl -s -X POST http://127.0.0.1:8080/run/close \
  -H 'Content-Type: application/json' \
  -d '{"run_id":"example-run"}'

Run records

Run records are local to the deployment surface under /data.

Default container path:

Mount /data when run records should survive restarts.

Observation, journald access, stderr collection, bea-series error packets, Milky receipts, Hammer packaging, and LLM handoff remain April-stack responsibilities.

Operational notes

Scope

This package is:

This package is not:

Version