Skip to main content

CLI for interacting with Keyhole-compatible runtimes

Project description

keyhole-cli

CLI for interacting with Keyhole-compatible runtimes.

Install

pip install keyhole-cli

Verify installation:

keyhole --help

Quick Example

Start the test runtime:

docker compose up

Run commands:

keyhole runtime health
keyhole runtime identity
keyhole runtime state
keyhole runtime realize sha256:abc123

Replay the same digest:

keyhole runtime realize sha256:abc123

The runtime returns ALREADY_REALIZED.

Commands

keyhole runtime health

Checks runtime liveness.

keyhole runtime health
# Equivalent to: GET /healthz

keyhole runtime identity

Returns runtime identity and capabilities.

keyhole runtime identity
# Equivalent to: GET /identity

keyhole runtime state

Displays the current runtime state.

keyhole runtime state
# Equivalent to: GET /state

keyhole runtime realize

Submits a realization request using a candidate digest.

keyhole runtime realize sha256:abc123
# Equivalent to: POST /realize {"candidate_digest": "sha256:abc123", "payload": {}}

Options:

  • --payload-json '{"key": "value"}' — inline JSON payload
  • --payload-file path/to/payload.json — JSON payload from file
  • --base-url — override runtime URL

Configuration

The CLI defaults to http://localhost:8080.

Override via environment variable:

export KEYHOLE_RUNTIME_URL=http://your-runtime:8080
keyhole runtime health

Or per-command:

keyhole runtime health --base-url http://your-runtime:8080

Relationship to the SDK

The CLI is built on top of the keyhole-sdk Python package. The SDK provides the programmatic interface; the CLI wraps it for terminal use.

License

Apache 2.0 — see LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

keyhole_cli-0.3.1.tar.gz (67.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

keyhole_cli-0.3.1-py3-none-any.whl (90.9 kB view details)

Uploaded Python 3

File details

Details for the file keyhole_cli-0.3.1.tar.gz.

File metadata

  • Download URL: keyhole_cli-0.3.1.tar.gz
  • Upload date:
  • Size: 67.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for keyhole_cli-0.3.1.tar.gz
Algorithm Hash digest
SHA256 75cd28370dd0c42418e0851061798b59d6e75c3e63a79b7c7762219c7347c5c3
MD5 d6432602499234ebef950909db1d9873
BLAKE2b-256 62cac8e5994badb255d99937b872592803e3dfbfdc505dae4739361248170985

See more details on using hashes here.

File details

Details for the file keyhole_cli-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: keyhole_cli-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 90.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for keyhole_cli-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 608843e30e449662d49bc8a23c04a6931ef9e05694b1129e45204d715aa13597
MD5 a3b46285c7fae5c022b02fce1a318a0d
BLAKE2b-256 2c7b7797d74125e878868fb40687e5894dc86efb39ced22b1d687153d58dd937

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page