Project Scaffold
dagster-rocky 0.4 ships two ways to bootstrap a new project:
dg scaffold defs dagster_rocky.RockyComponent <name>— uses Dagster’s built-in scaffolder via the registered entry point. Writes a baredefs.yaml.init_rocky_project(target_dir)— Python helper that writes a complete skeleton withdefs.yaml,rocky.toml,models/, and aREADME.md.
dg scaffold (canonical)
Section titled “dg scaffold (canonical)”After installing dagster-rocky, the dg CLI automatically discovers
RockyComponent via the
[project.entry-points."dagster_dg_cli.registry_modules"] entry in
dagster-rocky’s pyproject.toml.
uv add dagster-rockyuv run dg list components | grep -i rocky# dagster_rocky.RockyComponent
uv run dg scaffold defs dagster_rocky.RockyComponent my_pipelineThis writes a single my_pipeline/defs.yaml with type: dagster_rocky.RockyComponent.
init_rocky_project (richer)
Section titled “init_rocky_project (richer)”For a complete project skeleton, use the Python helper:
from pathlib import Pathfrom dagster_rocky import init_rocky_project
init_rocky_project(Path("my_pipeline"))After running, my_pipeline/ contains:
my_pipeline/├── defs.yaml # type: dagster_rocky.RockyComponent + attributes├── rocky.toml # DuckDB-backed starter, freshness preconfigured├── models/ # empty, with .gitkeep│ └── .gitkeep└── README.md # quickstart instructionsThe default rocky.toml uses the DuckDB local-execution adapter so the
scaffold runs end-to-end without warehouse credentials. The freshness config
is included to demonstrate the T1.1 wiring.
Overwrite protection
Section titled “Overwrite protection”init_rocky_project refuses to overwrite existing files by default — pass
overwrite=True to force:
init_rocky_project(Path("my_pipeline"), overwrite=True)This protects accidental re-runs from clobbering user edits to rocky.toml,
defs.yaml, or README.md.
Quickstart for end users
Section titled “Quickstart for end users”After scaffolding, the README guides users through:
# Install the rocky binary (once)curl -fsSL https://raw.githubusercontent.com/rocky-data/rocky/main/engine/install.sh | bash
# Validate the pipeline locally (DuckDB, no credentials required)rocky run --config rocky.toml
# Launch the Dagster UIdg dev