.amika/config.toml. When a sandbox is created from a repository, Amika reads
this file and applies the settings automatically — every collaborator gets the
same environment without passing extra flags.
This page is the reference-tab summary. For the full concept guide — including
multi-repo and repo-less sandboxes — see
How configuration works. For the field-by-field spec,
see the config.toml reference.
File location
--git
with amika sandbox create, or when creating a sandbox from a repository on the
hosted platform.
Configuration resolution
Repository configuration acts as a template for sandboxes. Settings can come from multiple sources, and Amika resolves them in priority order:
The first non-empty value wins. Each configuration dimension (setup script,
start script, env vars, services, sandbox settings, additional repos, and agent
credential defaults) is resolved independently.
Sections at a glance
.amika/config.toml has these tables. Each links to its full spec.
[lifecycle] — Setup and start scripts
Lifecycle scripts run at sandbox initialization. Paths are relative to the
repository root.
setup_scriptruns once before the container command starts, mounted at/usr/local/etc/amikad/setup/setup.sh, with the working directory set to$AMIKA_AGENT_CWD. It must be executable and exit0. Passing--setup-scripttoamika sandbox createtakes priority.start_scriptruns each time a stopped sandbox is started again — not on the initial create. It is re-read on each start. Use it for steps that must repeat on resume (starting a dev server, re-opening a tunnel).
See the
[lifecycle] spec for full details.
[filesystem] — Additional repos
Clone extra repositories into the sandbox alongside the primary repo.
~/workspace/<repo-name>. The primary repo is inferred automatically and need
not be listed.
See the [filesystem] spec for validation and
merge semantics.
Branch selection
When--branch is specified on amika sandbox create, the .amika/config.toml
file is read from that branch rather than the repository’s default branch. This
allows different branches to carry different sandbox configurations.
Example
Given this repository layout:config.toml:
amika sandbox create --git from anywhere inside my-project will:
- Clone the repository into the sandbox.
- Mount
.amika/setup.shas the setup script. - Set
NODE_ENV=developmentand resolveAPI_KEYfrom the secrets store. - Publish port 3000 with an HTTP URL.
- Use the
coderpreset with medium resource allocation.
Related docs
- How configuration works — concept guide: precedence, multi-repo, repo-less
- config.toml reference — full field-by-field spec
- Sandbox configuration — CLI flags, credential mounting, reserved ports
- Services — full
[services.<name>]reference