Sign inSign up

evilfreelancer/coddybot

By evilfreelancer

Updated 6 months ago

Coddy Bot - is an autonomous development assistant that integrates with Git hosting platforms.

Image
API management
Machine learning & AI
Developer tools
0

1.9K

evilfreelancer/coddybot repository overview

Coddy Bot

COmmunity Driven Development, Yep - is an autonomous development assistant that integrates with Git hosting platforms.

When you assign it to a GitHub issue (or give it a PR number), it plans the work, edits code using an AI agent, pushes branches, and opens pull requests.

docker pull evilfreelancer/coddybot:latest

Coddy consists of two modules:

  • Observer – webhook server; receives events, runs the planner when the bot is assigned, writes issue/PR metadata to .coddy/issues/ and .coddy/prs/.
  • Worker – development loop; reads queued issues, runs the AI agent, creates branches, commits, and PRs.

They run as two services in Docker Compose and share a workspace volume (sources and .coddy/).

Quick start (single container)

For a minimal local setup you need:

  • config.yaml on the host (copy from config.example.yaml in the repo)
  • A workspace directory with a clone of the target repo
  • GitHub token and webhook secret

You can run observer and worker as two separate docker run containers. Use the same image and the same workspace path; only the command and env vars differ.

Observer (webhook server, exposes port 8000):

docker run --rm -p 8000:8000 \
  -e GITHUB_TOKEN=your_github_token \
  -e WEBHOOK_SECRET=your_webhook_secret \
  -e BOT_WORKSPACE_PATH=/app/workspace \
  -v $(pwd)/config.yaml:/app/config.yaml:ro \
  -v /path/to/your/target-repo:/app/workspace:rw \
  evilfreelancer/coddybot:latest \
  python -m coddy observer --config /app/config.yaml

Worker (no port; shares workspace with observer):

docker run --rm \
  -e GITHUB_TOKEN=your_github_token \
  -e CURSOR_AGENT_TOKEN=your_cursor_agent_token \
  -e BOT_WORKSPACE_PATH=/app/workspace \
  -v $(pwd)/config.yaml:/app/config.yaml:ro \
  -v /path/to/your/target-repo:/app/workspace:rw \
  evilfreelancer/coddybot:latest \
  python -m coddy worker --config /app/config.yaml

Docker Compose example

services:
  coddy-observer:
    restart: unless-stopped
    image: evilfreelancer/coddybot:latest
    container_name: coddy-observer
    secrets:
      - github_token
      - webhook_secret
    environment:
      GITHUB_TOKEN_FILE: /run/secrets/github_token
      WEBHOOK_SECRET_FILE: /run/secrets/webhook_secret
      BOT_REPOSITORY: "${BOT_REPOSITORY:-EvilFreelancer/coddy}"
      BOT_WORKSPACE_PATH: "${BOT_WORKSPACE_PATH:-/app/workspace}"
      OBSERVER_SYNC_ON_STARTUP: "${OBSERVER_SYNC_ON_STARTUP:-false}"
    volumes:
      - ./config.yaml:/app/config.yaml:ro
      - ${REPO_PATH:-.}:/app/workspace:rw
      - ${SSH_DIR:-${HOME}/.ssh}:/home/coddy/.ssh:ro
    command: ["python", "-m", "coddy", "observer", "--config", "/app/config.yaml"]
    ports:
      - "${CODDY_PORT:-8000}:8000"
    logging:
      driver: "json-file"
      options:
        max-size: "100k"

  coddy-worker:
    restart: unless-stopped
    image: evilfreelancer/coddybot:latest
    container_name: coddy-worker
    secrets:
      - github_token
      - cursor_agent_token
    environment:
      GITHUB_TOKEN_FILE: /run/secrets/github_token
      CURSOR_AGENT_TOKEN_FILE: /run/secrets/cursor_agent_token
      BOT_REPOSITORY: "${BOT_REPOSITORY:-EvilFreelancer/coddy}"
      BOT_WORKSPACE_PATH: "${BOT_WORKSPACE_PATH:-/app/workspace}"
      CURSOR_CLI_TIMEOUT: "${CURSOR_CLI_TIMEOUT:-600}"
    volumes:
      - ./config.yaml:/app/config.yaml:ro
      - ${REPO_PATH:-.}:/app/workspace:rw
      - ${CODDY_SSH_DIR:-${HOME}/.ssh}:/home/coddy/.ssh:ro
    command: ["python", "-m", "coddy", "worker", "--config", "/app/config.yaml"]
    depends_on:
      - coddy-observer
    logging:
      driver: "json-file"
      options:
        max-size: "100k"

secrets:
  github_token:
    file: .secrets/github_token
  webhook_secret:
    file: .secrets/webhook_secret
  cursor_agent_token:
    file: .secrets/cursor_agent_token
  • ./workspace should contain a clone of the repository where Coddy will work.
  • Both services share the same workspace volume so they see the same repo and .coddy/ directory.

Example .env

# Path inside the container where the workspace (target repo) is mounted
BOT_WORKSPACE_PATH=/app/workspace

# GitHub token and webhook secret provided via Docker secrets
GITHUB_TOKEN_FILE=/run/secrets/github_token
WEBHOOK_SECRET_FILE=/run/secrets/webhook_secret

# Optional Cursor User API key for the Cursor CLI agent
CURSOR_AGENT_TOKEN_FILE=/run/secrets/cursor_agent_token

# Optional: SSH directory on the host if you use SSH remotes for git
CODDY_SSH_DIR=/home/youruser/.ssh

You can also set REPO_PATH to point to the repo inside the workspace if you need a non-default layout, for example:

REPO_PATH=/app/workspace

Workspace and secrets

  • Workspace

    • BOT_WORKSPACE_PATH must point to a directory that contains the target Git repository.
    • The bot clones, checks out branches, runs git commands and stores .coddy/ metadata inside this workspace.
    • Use a dedicated directory for the workspace (for example ./workspace on the host).
  • Secrets

    • Do not put .secrets/ inside the workspace directory. Anything in the workspace is visible inside the container and to tools running in it.
    • Recommended pattern:
      • Keep .secrets/ only on the host, outside the workspace.
      • Expose tokens via Docker secrets and the *_FILE environment variables, as in the examples above.
    • Required secrets:
      • GitHub token with push access to the target repo (for branches, commits, PRs).
      • Webhook secret that matches your GitHub Webhook configuration.
      • Optional Cursor User API key for the Cursor CLI agent. If not provided, you can use a stub agent instead.

With this setup, you can safely run Coddy Bot in Docker while keeping your workspace clean and your secrets outside of the repository.

Tag summary

Content type

Image

Digest

sha256:1e344e838

Size

215.4 MB

Last updated

6 months ago

docker pull evilfreelancer/coddybot