Skip to content

autonomouslogic/claude-container

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Claude Code Container

Run Claude Code in an isolated Docker container.

The main goal of this project is to provide a way to run Claude Code in a way that is as close as possible to running it directly, but still containing it and all executions inside a Docker container. See this blog post for more.

This is based on base-image which has a number of pre-installed tools. That image is further based on Containerbase, which is based on Ubuntu.

Usage

Copy the claude executable file into a path directory accessible by your shell, such as ~/.local/bin. The file is self-contained, so you can rename it, if you want.

Then simply navigate to the directory you want to run Claude Code in and execute claude as normal. Claude Code will now start inside a Docker container and you will be given a shell as normal.

Limitations

There are a number of limitations inherent in running inside a Docker container:

  • Only the current directory is accessible
  • Only tools installed on the Docker image are available, see base-image

Contributing

Contributions are very welcome. This project was deliberately made as simple as possible to address the core need without changing the workflow. If something doesn't work on your system, feel free to submit a PR. If you want more development tools installed, submit a PR to base-image.

License

Code in this repo is licensed under MIT-0.

Claude Code itself, as well as code in the ext directory, is owned by Anthropic and is licensed under different terms.

Resources

Various resources used to set this up.

Other Projects

About

Run Claude Code in an isolated Docker container

Resources

License

Stars

Watchers

Forks

Contributors