Skip to main content

Process watchdog CLI for monitoring and restarting services

Project description

🔹 Task 3: Service Monitor & Auto-Restart

Goal:

Monitor if a process is running. If not, restart it.

Example:

procwatch --pid 34349

procwatch --match "python server.py"
procwatch --port 8000

Requirements:

  • Check every N seconds
  • Log events
  • Handle failures
  • Timeout protection

Multiple cli

procwatch --match "python -m http.server 8000" --restart "python -m http.server 8000"
procwatch --port 8000 --restart "/usr/bin/startmyapp" --interval 4

Skills Learned:

  • Loop automation
  • Subprocess execution
  • Timeouts
  • Basic watchdog design

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

procwatch_cli-0.1.3.tar.gz (5.3 kB view details)

Uploaded Source

Built Distribution

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

procwatch_cli-0.1.3-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file procwatch_cli-0.1.3.tar.gz.

File metadata

  • Download URL: procwatch_cli-0.1.3.tar.gz
  • Upload date:
  • Size: 5.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for procwatch_cli-0.1.3.tar.gz
Algorithm Hash digest
SHA256 e97fe806bc5dfd77f47ff499389c7486f90fd4c62fbe99a5841ae9e8d206a70e
MD5 51469f475bb7bf2c2235f11b99279051
BLAKE2b-256 94bceab0d03d6f9cca568f7b5719f731c197d07f2e61b633a6e59c42ec081f64

See more details on using hashes here.

File details

Details for the file procwatch_cli-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: procwatch_cli-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for procwatch_cli-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 c1eaf1129c00a8126a8cd787f740c2bd7586d5843dfb888f276f8f59fef4227f
MD5 82d26af8c7dacc161cd92d4dc29177f3
BLAKE2b-256 bd050df611649bc8dc3dd4ccace704c9cc715fe6af85af2b714b6d37f073645c

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