Skip to main content

airflow-supervisor

Run and monitor supervisord-managed jobs from Apache Airflow.

Build Status codecov License PyPI

Manage a dedicated supervisord instance on an Airflow worker or an SSH host. Define its programs directly in a Python DAG or in airflow-config YAML.

from datetime import datetime, timezone

from airflow import DAG
from airflow_supervisor import ProgramConfiguration, Supervisor, SupervisorAirflowConfiguration

with DAG(
    dag_id="nightly-supervisor",
    schedule="@daily",
    start_date=datetime(2025, 1, 1, tzinfo=timezone.utc),
    catchup=False,
) as dag:
    supervisor = Supervisor(
        dag=dag,
        cfg=SupervisorAirflowConfiguration(
            working_dir="/var/tmp/nightly-supervisor",
            port="127.0.0.1:9001",
            program={"nightly": ProgramConfiguration(command="/bin/sleep 5")},
        ),
    )

The lifecycle writes configuration, starts supervisord and its programs, monitors program state with airflow-ha, and stops and removes the instance on successful completion. SupervisorSSH runs configuration and daemon commands over SSH; program control and checks use the remote XML-RPC endpoint.

Documentation

Start with the tutorial to run a self-contained local job and check its cleanup. For an existing deployment, choose a how-to guide:

Execution Inline Python airflow-config YAML
Local worker Run a local job Configure a local job
SSH host Run a job over SSH Configure an SSH job

The API reference describes configuration fields, defaults, and DAG constraints. Why Airflow delegates process ownership explains worker placement, SSH and XML-RPC, and the Python/YAML configuration choices.

Use the log forwarding and health-check guide to collect program output in task logs and monitor retained services between runs.

Published documentation is available at airflow-laminar.github.io/airflow-supervisor.

Ecosystem

Metadata

Release files for airflow-supervisor 1.11.0

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

Source distribution (sdist)

Source distribution for airflow-supervisor 1.11.0
File Size Uploaded
airflow_supervisor-1.11.0.tar.gz 26.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for airflow-supervisor 1.11.0
File Interpreter ABI Platform
airflow_supervisor-1.11.0-py3-none-any.whl Python 3 none any Details

Total release size: 65.0 kB

Release files / airflow_supervisor-1.11.0.tar.gz

Download URL airflow_supervisor-1.11.0.tar.gz
Size 26.4 kB
Tags Source
SHA-256 checksum
How to use checksums
ecaecbdce28bd3031bc51805400fa95446b441875c2c7d70149cd3c7a5df325a
BLAKE2b-256 checksum
How to use checksums
c19ed4f54f6927887a9c38e15ee453e19e67680403b0c5ee4a17589c9e880ea4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release files / airflow_supervisor-1.11.0-py3-none-any.whl

Download URL airflow_supervisor-1.11.0-py3-none-any.whl
Size 38.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
051e0a0488727505e2f09a2059190f9a165049b40788b726e41836bc45cb5c6f
BLAKE2b-256 checksum
How to use checksums
b6c64958a4a9f8fcefe8d77e3087b1ed8f551ef60fe553d89678d03b9e1e5570
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release history Release notifications | RSS feed

This release

1.11.0 This release

2 release files

1.10.4

2 release files

1.10.2

2 release files

1.10.1

2 release files

1.10.0

2 release files

1.9.4

2 release files

1.9.3

2 release files

1.9.2

2 release files

1.9.1

2 release files

1.9.0

2 release files

1.8.0

2 release files

1.7.10

2 release files

1.7.9

2 release files

1.7.8

2 release files

1.7.7

2 release files

1.7.6

2 release files

1.7.5

2 release files

1.7.4

2 release files

1.7.3

2 release files

1.7.2

2 release files

1.7.1

2 release files

1.7.0

2 release files

1.6.4

2 release files

1.6.3

2 release files

1.6.2

2 release files

1.6.1

2 release files

1.6.0

2 release files

1.5.1

2 release files

1.5.0

2 release files

1.4.2

2 release files

1.4.1

2 release files

1.4.0

2 release files

1.3.0

2 release files

1.2.2

2 release files

1.2.1

2 release files

1.2.0

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.1

2 release files

0.1.0

2 release files

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