Skip to main content

Python daemonizer for Unix, Linux and OS X.

Project description

Python daemonizer for Unix, Linux and OS X.

This library is a fork of python-daemon developed originally by serverdensity.

Install

pip install servd

Usage

It has a very simple usage and only requires a pid file to keep track of the daemon. The run() method should be overrided.

from servd import Daemon


class Service(Daemon):
    def __init__(self, pidfile) -> None:
        super().__init__(pidfile)

    def run(self) -> None:
        """Service code."""


service = Service("service.pid")

# Start service daemon
service.start()

# Restart service daemon
service.restart()

# Stop service daemon
service.stop()

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

servd-1.0.0.tar.gz (11.3 kB view details)

Uploaded Source

Built Distribution

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

servd-1.0.0-py2.py3-none-any.whl (11.5 kB view details)

Uploaded Python 2Python 3

File details

Details for the file servd-1.0.0.tar.gz.

File metadata

  • Download URL: servd-1.0.0.tar.gz
  • Upload date:
  • Size: 11.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.13 CPython/3.9.12 Linux/5.15.40-0-lts

File hashes

Hashes for servd-1.0.0.tar.gz
Algorithm Hash digest
SHA256 42f1175342080cd0bcccd857418a0170aa53967818c6ffdb549ac3593f5fed4d
MD5 da8d7647e2b8ec7ae03d6480f3bebdd0
BLAKE2b-256 1c5c6b959edeb2e2c05ca445df6949d847d68a6a044e8afbacfeb34e0a3b5c0d

See more details on using hashes here.

File details

Details for the file servd-1.0.0-py2.py3-none-any.whl.

File metadata

  • Download URL: servd-1.0.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 11.5 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.13 CPython/3.9.12 Linux/5.15.40-0-lts

File hashes

Hashes for servd-1.0.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 ee658b70df8c3a015216b023ddd1ebe276c73424dc978758a39946dd997e4a9c
MD5 d58004450f35ea5ca8c6f1ee61929777
BLAKE2b-256 cde2b3b0376f17731a9f78f04ccdbf77701e47f07701f7dbcfc8e3e0be4cb706

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