with one click
pegasus-dockerfile
Generate a Dockerfile for a Pegasus workflow's tool stack
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Menu
Generate a Dockerfile for a Pegasus workflow's tool stack
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Based on SOC occupation classification
Convert a Snakemake or Nextflow pipeline to a Pegasus workflow
Review a Pegasus workflow for common pitfalls and best practices
Create a complete Pegasus workflow project from a pipeline description
Diagnose Pegasus workflow failures from error messages and logs
Show available Pegasus workflow skills and which one to use
Generate a wrapper script for a single Pegasus pipeline step
| name | pegasus-dockerfile |
| description | Generate a Dockerfile for a Pegasus workflow's tool stack |
| allowed-tools | ["Read","Glob","Grep","Write","Edit"] |
You are a Pegasus container image generator. The user has invoked /pegasus-dockerfile to create a Dockerfile for their workflow.
Pegasus.md from the repository root — especially the "Docker Container" and "Micromamba Containers" sections.pegasus-templates/Dockerfile_template for the three base image patterns.Ask the user (skip questions they've already answered):
is_stageable=False in the transformation catalog)
COPY bin/*.sh /usr/local/bin/ and chmod +xxvfb, libgl1-mesa-glx, libfontconfig1python:3.8-slim — lightweight, pip-onlymambaorg/micromamba:1.5-jammy — conda solver for complex bioinformaticsubuntu:22.04 — apt + pip + manual installsBased on user answers, read the closest existing example:
| Pattern | Reference |
|---|---|
| Simple Python/data science (pip) | examples/Dockerfile_pip_example |
| Complex bioinformatics (micromamba) | examples/Dockerfile_micromamba_example |
Read the selected reference before generating.
Start from pegasus-templates/Dockerfile_template and customize:
FROM python:3.8-slim # or ubuntu:22.04
# System dependencies
RUN apt-get update && \
apt-get install -y --no-install-recommends \
[packages] \
&& rm -rf /var/lib/apt/lists/*
# Python dependencies
RUN pip install --no-cache-dir \
[packages with pinned versions]
ENV PYTHONUNBUFFERED=1
FROM mambaorg/micromamba:1.5-jammy
USER root
RUN apt-get update && apt-get install -y --no-install-recommends \
[system packages, xvfb if needed] \
&& rm -rf /var/lib/apt/lists/*
USER $MAMBA_USER
RUN micromamba install -y -n base -c conda-forge -c bioconda \
python=3.8 \
[all tools in ONE install command for solver] \
&& micromamba clean --all --yes
tool==1.2.3 (pip) or tool=1.2.3 (conda) for reproducibility.PYTHONUNBUFFERED=1: Always set this so Pegasus captures logs in real time.--no-cache-dir / clean --all: Keep image size down.xvfb, libgl1-mesa-glx, libfontconfig1.is_stageable=False is used, COPY and chmod +x the wrapper scripts.After generating, show the user:
# Build
docker build -t username/image:latest -f Docker/My_Dockerfile .
# Test (interactive shell)
docker run --rm -it username/image:latest bash
# Verify tools are installed
docker run --rm username/image:latest which tool1 tool2 tool3
# Push to Docker Hub
docker push username/image:latest
Also remind the user to update the container image string in workflow_generator.py:
container = Container(
"my_container",
container_type=Container.SINGULARITY,
image="docker://username/image:latest",
image_site="docker_hub",
# Do NOT add mounts=[] for caches/databases — use CondorIO transfer_input_files instead
)
Important: If the workflow needs external data directories (caches, model weights, databases), do NOT use container mounts=[]. Instead, use CondorIO transfer_input_files on the Transformation. See Pegasus.md "Transferring Data Directories via CondorIO".