Isolation
Run a project's commands in Docker or Podman, where the agent sees only the project and the folders you share.
Each project runs on this computer, in Docker, or in Podman. Choose it per project on the Runs on chip beside the prompt box. Set the default for new projects in Permissions & sandbox. A change restarts the project's container.
The image
KodaCode picks the image in this order:
- A Dockerfile chosen in settings.
.koda/Dockerfilein the project.- A base detected from the project: Rust, Node, Python, Go, JVM, .NET, PHP, Ruby, Swift or C++, from markers such as
Cargo.toml,package.json,pyproject.toml,go.modorpom.xml. - The default image,
ubuntu:24.04, or the Base image you set.
What the container sees
| The project | Mounted at /workspace, where the agent reads, builds, tests and edits. |
| A build cache | One per project, so downloads and builds don't run again. |
| Folders you allow | Only the Additional Directories you mark Mount in sandbox. |
| Skills | Shared read-only. Their scripts can run, but nothing in the container can rewrite them. |
| Everything else | Not there: your home folder, other repositories, the folder next door. |
Docker inside the container
Share Docker host gives a project's container a Docker of its own, so docker and docker compose work there. What they start runs in that Docker, apart from this machine's containers and volumes. Ports that they publish are forwarded to localhost on this machine.
The terminal
When a project runs in a container, open the terminal panel (⌘J or ⌃`). Choose Project container for a shell with the same tools, files and limits as the agent. Choose Host shell for your own machine. A goal that runs in a container has its own Goal container.
Approvals in a container
In a container, changes apply directly by default, and commands that reach outside the project are allowed. This is the default because the container holds only the project and what you share. On this computer, both ask first. You can change each setting per project. See Approvals.