Skip to main content

Pure-Python client for PM2's daemon RPC socket

Project description

pm2-rpc

Pure-Python client for PM2's daemon RPC socket.

[!CAUTION] Experimental (v0.1.0) — Early-stage personal project. The API will change without notice.

Talks directly to the ~/.pm2/rpc.sock Unix socket using PM2's pm2-axon / pm2-axon-rpc wire stack (AMP framing -> amp-message arg packing -> axon-rpc body). No pm2 CLI shell-out for the common cases.

Quick Start

import pm2

for p in pm2.list():
    print(p.pm_id, p.name, p.status)

pm2.stop("worker")
pm2.delete("worker")

Installation

pip install pm2-rpc

Requires Python >= 3.12 and a running PM2 daemon on the same host.

Development

uv sync --group dev
uv run pytest tests/        # requires a real PM2 daemon

License

MIT — 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

pm2_rpc-0.2.0.tar.gz (8.3 kB view details)

Uploaded Source

Built Distribution

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

pm2_rpc-0.2.0-py3-none-any.whl (9.9 kB view details)

Uploaded Python 3

File details

Details for the file pm2_rpc-0.2.0.tar.gz.

File metadata

  • Download URL: pm2_rpc-0.2.0.tar.gz
  • Upload date:
  • Size: 8.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.16 {"installer":{"name":"uv","version":"0.11.16","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for pm2_rpc-0.2.0.tar.gz
Algorithm Hash digest
SHA256 2d8a47206fac83cb8a09200e16fd2bd0fc38a9fa7405a767f27dbf8298891ab0
MD5 2aac64b5dbe12226eab1ab5822ef5a89
BLAKE2b-256 53b99aa6544df7374228b542a8bd8813bd50f8e526e0c08ee41bf6044d921d5d

See more details on using hashes here.

File details

Details for the file pm2_rpc-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: pm2_rpc-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 9.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.16 {"installer":{"name":"uv","version":"0.11.16","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for pm2_rpc-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 436ec58c4de6c7b91fd1b042276d60b999e5100058a338912c0fc1a35f90173d
MD5 3c9985f6c475b8e956ceeda973f337d4
BLAKE2b-256 c160cf20fe5cc7cf092e619ee05aa49e4b0c08ff9118ed56e2429a9f3856ddc8

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