| 1 | # Opt-in CodeWhale toolbox workflow. |
| 2 | # |
| 3 | # Usage: |
| 4 | # CODEWHALE_IMAGE=ghcr.io/hmbown/codewhale:vX.Y.Z \ |
| 5 | # CODEWHALE_TOOLBOX_IMAGE=codewhale-toolbox:my-project \ |
| 6 | # CODEWHALE_HOME_VOLUME=codewhale-my-project-home \ |
| 7 | # CODEWHALE_WORKSPACE="$PWD" \ |
| 8 | # docker compose -f docs/examples/compose.toolbox.yml run --rm codewhale |
| 9 | # |
| 10 | # Keep CODEWHALE_HOME_VOLUME distinct per project so sessions, config, skills, |
| 11 | # memory, and queued work do not bleed across workspaces. |
| 12 | |
| 13 | services: |
| 14 | codewhale: |
| 15 | image: ${CODEWHALE_TOOLBOX_IMAGE:-codewhale-toolbox:local} |
| 16 | build: |
| 17 | context: ../.. |
| 18 | dockerfile: docs/examples/Dockerfile.toolbox |
| 19 | args: |
| 20 | CODEWHALE_IMAGE: ${CODEWHALE_IMAGE:-ghcr.io/hmbown/codewhale:latest} |
| 21 | TOOLBOX_PACKAGES: ${TOOLBOX_PACKAGES:-git openssh-client curl build-essential pkg-config python3 python3-pip nodejs npm} |
| 22 | environment: |
| 23 | - DEEPSEEK_API_KEY=${DEEPSEEK_API_KEY:?set DEEPSEEK_API_KEY} |
| 24 | - DEEPSEEK_BASE_URL |
| 25 | - DEEPSEEK_NO_COLOR |
| 26 | volumes: |
| 27 | - codewhale-home:/home/codewhale/.codewhale |
| 28 | - ${CODEWHALE_WORKSPACE:?set CODEWHALE_WORKSPACE to the project directory}:/workspace |
| 29 | # Mount SSH material only for projects that need it, and prefer read-only. |
| 30 | # - ${HOME}/.ssh:/home/codewhale/.ssh:ro |
| 31 | # Mount local CA certificates only when starting through a command that |
| 32 | # runs `sudo update-ca-certificates` inside this toolbox image. |
| 33 | # - ${CODEWHALE_CERTS_DIR:-../../docker/certs}:/usr/local/share/ca-certificates/local:ro |
| 34 | working_dir: /workspace |
| 35 | stdin_open: true |
| 36 | tty: true |
| 37 | |
| 38 | volumes: |
| 39 | codewhale-home: |
| 40 | name: ${CODEWHALE_HOME_VOLUME:-codewhale-toolbox-home} |
| 41 |