Skip to main content

keepstart

Monitor keepalived status, run start.sh if server get MASTER role, and run stop.sh if server get SLAVE role.

Install

pip install keepstart

Example Config

application:
    daemon: false
    pidfile: jenkins-keep.pid

keepstart:
    nic: eth0
    vip: 172.18.1.44
    start: /opt/app/start.sh
    stop: /opt/app/stop.sh
    is-running: /opt/app/status.sh

logging:
    version: 1
    disable_existing_loggers: false
    formatters:
        simple:
        format: "%(asctime)-15s\t%(levelname)s\t%(message)s"
    handlers:
        console:
            class: logging.StreamHandler
            level: DEBUG
            formatter: simple
    loggers:
        keepstart:
            level: DEBUG
            handlers:
                - console
            propagate: no
    root:
        level: DEBUG
        handlers:
            - console

Server command

keepserver -c config.yaml start
keepserver -c config.yaml stop
keepserver -c config.yaml reload

Command help

zencoreDeMacPro:keepstart zencore$ keepserver --help
Usage: keepserver [OPTIONS] COMMAND [ARGS]...

Options:
-c, --config FILENAME  Config file path, use yaml format. Default to
                        config.yaml.
--help                 Show this message and exit.

Commands:
reload  Reload application server.
start   Start application server.
stop    Stop application server.
zencoreDeMacPro:keepstart zencore$

Metadata

Release files for keepstart 0.1.3

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

Source distribution (sdist)

Source distribution for keepstart 0.1.3
File Size Uploaded Provenance Actions
keepstart-0.1.3.tar.gz 4.3 kB Without provenance Details for keepstart-0.1.3.tar.gz

Release files / keepstart-0.1.3.tar.gz

Download URL keepstart-0.1.3.tar.gz
Size 4.3 kB
Tags Source
SHA-256 checksum
How to use checksums
6f5b1d5b6174106d6cceae113cf36e50449f4c1f99999240bfcf8a19867b7eb9
BLAKE2b-256 checksum
How to use checksums
84df4bb63e9261224475db01400b0f2af08e486e5603d623f36f67b3ec23f160
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for keepstart 0.1.3

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