Skip to main content

Description

Adds mstop, mstart and mrestart commands to Supervisor. Those commands works similar to stop, start and restart respectively, but they:

  • add support for process name wildcarding,

  • sends the start/stop/restart signal in parallel (which makes the batch commands finish faster).

In some usecases you can use groups support in Supervisor, but it doesn’t allow you to have one process in multiple groups. That’s when wildcarding can be really useful.

Example

supervisor> status
celery-a                                RUNNING    pid 15085, uptime 0:00:11
celery-b                                RUNNING    pid 15086, uptime 0:00:12
gunicorn-a                              RUNNING    pid 14151, uptime 0:05:18
gunicorn-b                              RUNNING    pid 14237, uptime 0:04:45
supervisor> mstop *-a
celery-a: stopped
gunicorn-a: stopped
supervisor>

Installation

pip install supervisor-wildcards

And then add into your supervisor.conf:

[ctlplugin:wildcards]
supervisor.ctl_factory = supervisorwildcards.controllerplugin:make_wildcards_controllerplugin

Configuration

[ctlplugin:wildcards]
supervisor.ctl_factory = supervisorwildcards.controllerplugin:make_wildcards_controllerplugin
match_group = 1

By default, supervisorwildcards plugin match the wildcards just against process name (not group). Setting match_group = 1 will try to match the pattern against “group_name:process_name” instead.

Changelog

  • 0.1.3

    • all parameter expands to *

    • Added match_group config option

  • 0.1.2

    • Fixed matching processes that are assigned to a group

  • 0.1.1

    • Commands are run in parallel (Thanks, Honza Kral)

  • 0.1.0

    • Simple support for mstop, mstart, mrestart

Metadata

Release files for supervisor-wildcards 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 supervisor-wildcards 0.1.3
File Size Uploaded
supervisor-wildcards-0.1.3.tar.gz 2.6 kB Details

Release files / supervisor-wildcards-0.1.3.tar.gz

Download URL supervisor-wildcards-0.1.3.tar.gz
Size 2.6 kB
Tags Source
SHA-256 checksum
How to use checksums
02f532bf059e99aa38a3170cf4295f9dd123cfb16f209240575d853fd90710f8
BLAKE2b-256 checksum
How to use checksums
cb78ce6bf00c3310660ab9ebd7c4656a9ebf888a42a58b95a7565b03d40c2f00
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.1.3 This release

1 release file

0.1.1

1 release file

0.1.0

1 release file

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