Internal/External
Internal
Area
cardano-testnet
1. Machine-readable runtime interface (manifest and status)
Problem
When cardano-testnet cardano starts a network it knows every socket path, port, and key location. But it only communicates them as human-oriented log text and an undocumented directory layout.
Programs that start cardano-testnet must therefore scrape the output directory and poll with their own retry loops. Consumers usually build this layer independently: cardano-transaction-lib parses the run directory (their integration doc), the YACD Kubernetes operator wraps the binary, and Tweag's cardano-peras repo wraps it again.
The request is old and still open: #5848 (2024) asks for "more structured output (e.g. JSON) so that we can parse the TMP dir to get the node socket path, etc.".
Proposal
- Manifest. On successful startup, write
<output-dir>/manifest.json: network magic, era, and per node: name, role, socket path, port, config path; plus the funded key files. Document it as a stable interface, so the rest of the directory layout can keep changing freely.
- Status command.
cardano-testnet status --output-dir DIR [--json]: reports ready/synced/tip, exit code 0 only when the chain is producing blocks.
References
#5848 · #6405 (keep-running behavior)
Internal/External
Internal
Area
cardano-testnet
1. Machine-readable runtime interface (manifest and status)
Problem
When
cardano-testnet cardanostarts a network it knows every socket path, port, and key location. But it only communicates them as human-oriented log text and an undocumented directory layout.Programs that start
cardano-testnetmust therefore scrape the output directory and poll with their own retry loops. Consumers usually build this layer independently:cardano-transaction-libparses the run directory (their integration doc), the YACD Kubernetes operator wraps the binary, and Tweag'scardano-perasrepo wraps it again.The request is old and still open: #5848 (2024) asks for "more structured output (e.g. JSON) so that we can parse the TMP dir to get the node socket path, etc.".
Proposal
<output-dir>/manifest.json: network magic, era, and per node: name, role, socket path, port, config path; plus the funded key files. Document it as a stable interface, so the rest of the directory layout can keep changing freely.cardano-testnet status --output-dir DIR [--json]: reports ready/synced/tip, exit code 0 only when the chain is producing blocks.References
#5848 · #6405 (keep-running behavior)