Runtimes
A runtime is the CI/CD environment where autoducks agents execute. The runtime is responsible for:
- Listening for triggers (issue comments, PR merges, workflow dispatch)
- Setting environment variables for the agent scripts
- Granting repository permissions to the agent process
- Invoking
pre.sh, the LLM agent, andpost.shin sequence
The agent scripts themselves (pre.sh, post.sh, and the core utilities in .autoducks/) are runtime-agnostic. Only the workflow definitions that wire triggers to scripts are runtime-specific.
Supported runtimes
Section titled “Supported runtimes”| Runtime | Status | Workflow files |
|---|---|---|
github-actions | ✅ Supported | .autoducks/runtimes/github-actions/ |
How runtimes work
Section titled “How runtimes work”Runtime workflow files live under .autoducks/runtimes/{runtime}/. At install time, the installer copies them to wherever the CI/CD platform expects to find them.
For GitHub Actions:
.autoducks/runtimes/github-actions/autoducks-*.yml → .github/workflows/autoducks-*.ymlThe setup.sh script verifies that the deployed workflow files stay in sync with the canonical definitions in .autoducks/runtimes/.
Adding a new runtime
Section titled “Adding a new runtime”To support a new CI/CD platform, create a new directory under .autoducks/runtimes/{runtime}/ with workflow files that:
- Listen for the appropriate triggers (issue comment, PR merge, workflow/pipeline dispatch)
- Set the required environment variables (
ISSUE_NUM,BASE_BRANCH,REPO,COMMENT_ID,RUN_ID,GH_TOKENor equivalent) - Call the agent
pre.sh, then the LLM step, thenpost.sh— orrun.shfor bash-only agents
The agent scripts and provider implementations do not need to change.