maqpna dev up
Start a local MAQPNA: identity broker, gateway and the mcp-echo test MCP server
Synopsis#
maqpna dev up [--dir .maqpna] [--gateway-port 8080] [--identity-port 8081] [--echo-port 8090] [--policy FILE]
[--upstream NAME=URL]... [--model NAME=URL[,MODEL]] [--stub-llm [--stub-llm-script F]] [--no-echo] [--from-source]
[--dlp-profile FILE] [--checkpoint-key FILE] [--gateway-config FILE]
[--llamay MODEL [--llamay-bin PATH] [--llamay-port 11435]] [--kosa8 [--kosa8-host-ip IP]]
[--client-audit FILE [--client-audit-pubkey HEX]]Description#
From the help of maqpna dev:
up starts maqpna-identity, maqpna-gateway and (unless --no-echo) mcp-echo from the installed binaries (next to maqpna or on PATH); in a source checkout with --from-source, or when they are missing, they are built with go build. run mints a session token from the local broker and runs CMD with the same environment the operator gives a sandbox (MAQPNA_GATEWAY_URL, MAQPNA_TOKEN, MAQPNA_SESSION, MAQPNA_AGENT, MAQPNA_TOOL_<NAME>_URL), then prints what the session did. Exit code: CMD's. up --llamay MODEL also serves MODEL with llamay as model route "llamay": each session gets its own llamay inference context, forked with the session, and llamay's request audit is anchored in the ledger (fail closed). up --kosa8 serves the gateway on this host's LAN address and cross-anchors the ledger with kosa8d's audit; run --kosa8-image then runs CMD in a kosa8 microVM that can reach only the gateway, and fork live-forks a kept sandbox into a governed child session with its own token. snapshot checkpoints a kept sandbox together with its llamay inference contexts; restore boots the checkpoint as a new session (its own token, the checkpointed session as parent) and resumes those contexts. attest prints the sandbox's measurements (kernel, rootfs, image digests) and proves its egress is the gateway only (exit code 3 when it is not).
Flags#
| Flag | Type | Description | Default |
|---|---|---|---|
--checkpoint-key | string | audit checkpoint signing key (Ed25519, P-256 or RSA PKCS#8 PEM file; auditCheckpointKey) | none |
--client-audit | string | anchor a desktop agent's signed tool-call audit file in the ledger (docs/integrations/desktop-agent.md) | none |
--client-audit-pubkey | string | with --client-audit: pin the agent's device key (hex; default: hold the first verified key) | none |
--dir | string | state directory (keys, config, ledger, logs) | .maqpna |
--dlp-profile | string | DLP profile JSON file, applied to all traffic as profile "dev" (dlpProfiles.dev, dlp.defaultProfile) | none |
--echo-port | int | mcp-echo port | 8090 |
--from-source | switch | build the servers from this source checkout with go build | none |
--gateway-config | string | JSON object merged over the generated .maqpna/gateway.json (top-level keys replace; e.g. auditSinks, pricingFile) | none |
--gateway-port | int | gateway port | 8080 |
--identity-port | int | identity broker port | 8081 |
--kosa8 | switch | serve the gateway on this host's LAN address so agents in kosa8 sandboxes can reach it (dev run --kosa8-image), and cross-anchor the ledger with kosa8d's audit chain | none |
--kosa8-host-ip | string | with --kosa8: the host IPv4 address sandboxes dial (default: the LAN address of the default route) | none |
--llamay | string | also start llamay serve with this model (GGUF path or llamay store name) as model route "llamay": per-session inference contexts, forked with the session, and llamay's request audit anchored in the ledger | none |
--llamay-bin | string | llamay binary (default: llamay next to maqpna or on PATH) | none |
--llamay-port | int | llamay port | 11435 |
--model | string | OpenAI-compatible model route NAME=URL[,MODEL] (repeatable) | none |
--no-echo | switch | do not start the mcp-echo test server | none |
--policy | string | policy JSON file (default: the built-in dev policy) | none |
--stub-llm | switch | also start stub-llm (scripted OpenAI-compatible model, no API key) as model route "stub" | none |
--stub-llm-port | int | stub-llm port | 8000 |
--stub-llm-script | string | stub-llm script (YAML; default: call echo, then a denied delete, then answer) | none |
--upstream | string | extra MCP server NAME=URL (repeatable) | none |
The global flags (--context, -o, --no-color, ...) work with every command.
Examples#
# Start a local MAQPNA, run your agent under it, then see what it did
maqpna dev up
# Use a model route backed by the scripted stub model
maqpna dev up --stub-llm
# Serve a local model with llamay; run the agent in a kosa8 microVM and fork it
maqpna dev up --llamay qwen2.5:0.5b --kosa8What happens when you run it#
- Prints a table by default;
-o jsonor-o yamlprint the data, and--jq EXPRfilters the JSON.
Exit codes#
| Code | Meaning |
|---|---|
0 | success |
1 | error (the message says what failed, with a hint when there is one) |
2 | usage error: unknown flag, missing argument or bad value; the synopsis is printed |
3 | a check failed, a change is blocked, or a result did not match (tamper, policy mismatch) (not used by this command) |
Related commands#
Terminal demo#
Last updated