dagu

module
v1.17.0-beta.15 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 18, 2025 License: GPL-2.0, GPL-3.0

README ยถ

dagu-logo

Ask DeepWiki

Dagu

Overview

Dagu is a compact, portable workflow engine implemented in Go. It provides a declarative model for orchestrating command execution across diverse environments, including shell scripts, Python commands, containerized operations, or remote commands.

Daguโ€™s design emphasizes minimal external dependencies: it operates solely as a single binary without requiring an external database. A browser-based graphical interface (UI) is provided for real-time monitoring, rendering the status and logs of workflows. This zero-dependency structure makes the system easy to install and well-suited to various infrastructures, including local or air-gapped systems. This local-first architecture also ensures that sensitive data or proprietary workflows remain secure.

Table of Contents

๐Ÿ“ข Updates

  • 2025-05-30: v1.17.0-beta - Major UI improvements, hierarchical execution, and performance enhancements Your feedback is valuable! Please test the beta and share your experience:

    To try the beta: docker run --rm -p 8080:8080 ghcr.io/dagu-org/dagu:latest dagu start-all

  • 2025-01-09: v1.16.0 - Dotenv support, JSON reference expansion, enhanced preconditions, and improved parameter handling

Announcements

๐Ÿš€ Version 1.17.0-beta Available - Significant Improvements & New Features

We're excited to announce the beta release of Dagu 1.17.0! This release brings many improvements and new features while maintaining the core stability you rely on.

Key Features in 1.17.0:

  • ๐ŸŽฏ Improved Performance: Refactored execution history data for more performant history lookup
  • ๐Ÿ”„ Hierarchical Execution: Added capability for nested DAG execution
  • ๐Ÿ“„ Multiple DAGs in Single File: Define multiple DAGs in one YAML file using --- separator for better organization and reusability
  • ๐Ÿš€ Parallel Execution: Execute commands or sub-DAGs in parallel with different parameters for batch processing (#989)
  • ๐ŸŽจ Enhanced Web UI: Overall UI improvements with better user experience
  • ๐Ÿ“Š Advanced History Search: New execution history page with date-range and status filters (#933)
  • ๐Ÿ› Better Debugging:
    • Display actual results of precondition evaluations (#918)
    • Show output variable values in the UI (#916)
    • Separate logs for stdout and stderr by default (#687)
  • ๐Ÿ“‹ Queue Management: Added enqueue functionality for API and UI (#938)
  • ๐Ÿ—ฟ Partial failed: Added partial success status (#1011)
  • ๐Ÿ—๏ธ API v2: New /api/v2 endpoints with refactored schema and better abstractions (OpenAPI spec)
  • ๐Ÿ”ง Various Enhancements: Including #925, #898, #895, #868, #903, #911, #913, #921, #923, #887, #922, #932, #962

Please see the full changelog for all details and migration notes.

โค๏ธ Huge Thanks to Our Contributors

This release wouldnโ€™t exist without the communityโ€™s time, sweat, and ideas. In particular:

Contribution Author
Optimized Docker image size and split into three baseline images @jerry-yuan
Allow specifying container name & image platform ([#898]) @vnghia
Enhanced repeat-policy โ€“ conditions, expected output, and exit codes @thefishhat
Implemented queue functionality @kriyanshii
Implemented partial success status @thefishhat
Countless insightful reviews & feedback @ghansham

Thank you all for pushing Dagu forward! ๐Ÿ’™

Key Attributes

  • Small Footprint Dagu is distributed as a single binary with minimal resource overhead. It does not require additional components such as external databases, message brokers, or other services.

  • Language Agnostic: Workflows in Dagu are defined by specifying tasks (called โ€œstepsโ€) and their dependencies in YAML. A step can execute any command whether Python, Bash, Node.js, or other executables. This flexibility allows easy integration with existing scripts or tools.

  • Local-First Architecture: Dagu was designed to run on a single developer workstation or server. By default, all tasks, logs, and scheduling run locally, allowing run offline or in air-gapped environments. This architecture ensures that sensitive data or proprietary workflows remain secure.

  • Declarative Configuration: The workflow definition is contained in a YAML file. Dependencies, schedules, and execution details are declaratively expressed, making the workflow easy to comprehend and maintain.

  • No Complex Setup: Unlike other orchestration platforms (e.g., Airflow) that often require substantial infrastructure, Dagu can be installed in minutes. Just dagu start-all command spins up both the scheduler and web UI, ready to run tasks immediately.

Use Cases

  • Data ingestion pipelines
  • Data processing on small-scale/embedded systems
  • Media file conversion tasks
  • Automated workflows for employee onboarding and offboarding
  • CI/CD automation

Installation

Dagu can be installed in multiple ways, such as using Homebrew or downloading a single binary from GitHub releases.

Via Bash script

Install the latest version:

curl -L https://raw.githubusercontent.com/dagu-org/dagu/main/scripts/installer.sh | bash

Install a specific version:

curl -L https://raw.githubusercontent.com/dagu-org/dagu/main/scripts/installer.sh | bash -s -- --version <version>

The <version> can be a specific version (e.g. v1.16.10)

Install to a custom directory:

curl -L https://raw.githubusercontent.com/dagu-org/dagu/main/scripts/installer.sh | bash -s -- --install-dir <path>

Via GitHub Releases Page

Download the latest binary from the Releases page and place it in your $PATH (e.g. /usr/local/bin).

Via Homebrew (macOS)

brew install dagu-org/brew/dagu

Upgrade to the latest version:

brew upgrade dagu-org/brew/dagu

Via Docker

mkdir -p ~/.dagu
docker run \
--rm \
-p 8080:8080 \
-v ~/.dagu:/dagu \
-e DAGU_TZ=`ls -l /etc/localtime | awk -F'/zoneinfo/' '{print $2}'` \
ghcr.io/dagu-org/dagu:latest dagu start-all

Note: The environment variable DAGU_TZ is the timezone for the scheduler and server. You can set it to your local timezone (e.g. America/New_York).

See Environment variables to configure those default directories.

Quick Start

See the Quick Start Guide to create and execute your first DAG!

Building from Source

Dagu can be built and run locally from source.

Prerequisites

Make sure you have the following installed on your system:

Steps to Build Locally

1. Clone the repository
  • Clone the repository to your local machine using Git.
    git clone https://github.com/dagu-org/dagu.git
    cd dagu
    
2. Build the UI
  • Build the UI assets. This step is necessary to generate frontend files and copy them to the internal/frontend/assets directory.
    make ui
    
3. Build the Binary
  • Build the binary
    make bin
    
    This produces the dagu binary in the .local/bin directory.

Run Locally from Source

For a quick test of both server, scheduler, and UI:

# Runs "dagu start-all" with the `go run` command
make run

Once the server is running, visit http://127.0.0.1:8080 to see the Web UI.

Continue with the Quick Start Guide to create and execute your first DAG!

Web UI

Dashboard

The Dagu dashboard provides an overview of all workflows (DAGs) and their current status.

Dashboard

DAG Details

Create and edit workflows (DAGs) with auto completion and validation. The DAG editor allows you to define steps, dependencies, and parameters in a user-friendly interface.

DAG History

DAGs

View all DAGs in one place with live status updates.

DAGs

Search across all DAG definitions.

History

Execution History

Review past workflows and logs at a glance.

History

Log Viewer

Examine detailed step-level logs and outputs.

DAG Log

Contributing

Contributions to Dagu are welcome.

Contributors

License

Dagu is distributed under the GNU GPLv3.

Directories ยถ

Path Synopsis
api
v1
Package api provides primitives to interact with the openapi HTTP API.
Package api provides primitives to interact with the openapi HTTP API.
v2
Package api provides primitives to interact with the openapi HTTP API.
Package api provides primitives to interact with the openapi HTTP API.
internal
cmd
persistence/dirlock
Package dirlock provides a directory-based locking mechanism for coordinating access to shared resources across multiple processes.
Package dirlock provides a directory-based locking mechanism for coordinating access to shared resources across multiple processes.
scheduler/filenotify
Package filenotify provides a mechanism for watching file(s) for changes.
Package filenotify provides a mechanism for watching file(s) for changes.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL