act container "exited with code 137" (OOM) running Actions locally
Exit code 137 means the container received SIGKILL (128 + 9). During act runs this is almost always the out-of-memory killer: the job needed more RAM than Docker Desktop was allotted.
What this error means
A step or the whole job stops with "exited with code 137", often right after a memory-heavy build or test, with no application error printed.
act
[CI/build] container for step exited with code 137
Error: The process '/usr/bin/docker' failed with exit code 137Common causes
Docker Desktop memory limit is too low
Local Docker caps memory (often 2 to 4 GB by default). A build that fits GitHub-hosted 7 GB runners is killed locally.
A single step allocates more than available
A test suite or compiler spikes past the container limit and the OOM killer terminates the process.
How to fix it
Raise Docker Desktop memory
- Open Docker Desktop Settings, Resources, and increase the memory limit.
- Apply and restart Docker.
- Re-run act; the container now has headroom.
Reduce the step memory footprint
Limit parallelism in the memory-heavy step so it stays under the container ceiling.
Terminal
# run tests with fewer workers to cut peak memory
pytest -n 2How to prevent it
- Give Docker Desktop enough memory to mirror the 7 GB hosted runner.
- Cap parallelism in memory-heavy steps for local runs.
- Remember local resources differ from GitHub-hosted runners.
Related guides
act "OCI runtime exec format error" running Actions locallyFix act "OCI runtime create failed: ... exec format error" - a binary in the container was built for a differ…
act runner image differs from GitHub-hosted (missing preinstalled tools)Fix act "command not found" for tools that exist on GitHub-hosted runners - act images (medium size) omit man…
act "permission denied /var/run/docker.sock" running Actions locallyFix act "dial unix /var/run/docker.sock: connect: permission denied" - your user cannot access the Docker soc…