Skip to main content
sdog
====

A process monitor using an extremely limited (but still useful enough for me)
subset of the systemd watchdog protocol

"450 downloads in the last week" -- are people actually using this, or is pypi
just full of bots? o.o;; I welcome your feedback if you are actually a person :)

```
Usage: sdog [options] -- daemon-to-run [daemon options]

Options:
-h, --help show this help message and exit
-t N, --timeout=N Maximum seconds between pings
-r N, --respawn=N Delay between respawns
-s FILE, --socket=FILE Path to socket
-T NAME, --title=NAME Daemon name (defaults to the first param after "--")
(Requires setproctitle module)
-v, --verbose Verbose mode
```

For Daemons
===========

There is the sdog.notifier module

```
from sdog.notifier import SDNotifier

def main():
# Create the notifier
sd = SDNotifier()

# Connect to the work queue and signal that we're ready to go
work_queue = WorkQueue("localhost:1234")
sd.ready()

while True:
# Get some work and signal that we're working on it
item = work_queue.get()
sd.status("Processing %s" % item.name)

# Do the work then signal that we are alive and running successfully
do_some_work(item)
sd.watchdog()
```

Protocol
========

The daemon will be launched with `NOTIFY_SOCKET=/some/path.sock` in its
environment; it should then write datagram packets into this socket:

```
READY=1 -- signal that the daemon has loaded, and to start monitoring
WATCHDOG=1 -- must be sent at least once every $timeout seconds
STATUS=blah -- update the current status message
```

Metadata

Release files for SDog 0.2.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for SDog 0.2.2
File Size Uploaded Provenance Actions
SDog-0.2.2.tar.gz 4.0 kB Without provenance Details for SDog-0.2.2.tar.gz

Release files / SDog-0.2.2.tar.gz

Download URL SDog-0.2.2.tar.gz
Size 4.0 kB
Tags Source
SHA-256 checksum
How to use checksums
675b43a463562ca8383758982fe91b9089e2b89e834daaefe50b0c4aa3344023
BLAKE2b-256 checksum
How to use checksums
46bd4eaa6e53d111541b5e98f5ff8e29645c1a5cf755768089c6ddf8c43037bb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for SDog 0.2.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page