OpenCode (CAF)
As of 2026-03, the best setup for my coding needs seems to be OpenCode + OpenAgentControl.
See my research on assistanst and Coding Agent Frameworks.
Select Global (scope:dev-user, all projects), Profile:Full.
Evolution/Updates:
- Language Models:
opencode models --refresh - OpenCode:
opencode upgrade - OpenAgentsControl:
curl -fsSL https://raw.githubusercontent.com/darrenhinde/OpenAgentsControl/main/update.sh | bashwill update the OAC's agents in~/.config/opencode/agent, and then/initwill read them. Alternatively,/plugin install oacand/oac:setup --core.
Appendices#
All these will likely end up gathered as a shell/incat/docker script creating a standad development environment and feeding the company/group's rules and tools, so it can be shared among team mates or open source contributors.
Docker#
Call me paranoid, but my first attempt was the official dockerized OpenCode deployment as per OpenCode's documentation. It needs permission juggling between host and container, but it ensures control while it felt familiar ...and easy, until it no longer was.
The current bash installers for OpenAgentControl LGTM. The containerized setup comes handy
to re-inforce security. But the official container is a stripped-down Debian without bash
(needed for the OpenAgentControl installer), curl, nano, apt or dpkg.
This is fine for other purposes but not for mine.
Incus cli-dev-work#
We'll use incus, then. I have cli-dev-work as a container for general CLI development.
I'll use it for experimenting.
Install Curl, jq, and OpenCode#
As root:
apt install curl jq
curl -fsSL https://opencode.ai/install | bash
We could easily skip curl for the installation but jq is needed. I could install it
temporarily and remove it afterwards, but both are useful also for the agents,
so I left them installed.
I installed with a user, so the installer created a callable binary in the user's home. I had to move it for every user to use:
mv /root/.opencode/bin/opencode /usr/bin/
chown root:root /usr/bin/opencode
Now any user can call opencode.
su dev-user
opencode
This is likely not the proper procedure for a real multi-user installation, but it'll be just me disguised as different users because I'm accessing from different machines or containers.
Configure OpenCode#
Within OpenCode:
/connect
Use Shift-Ctrl-V to paste the API key.
Install OpenAgentControl#
As dev-user:
curl -fsSL https://raw.githubusercontent.com/darrenhinde/OpenAgentsControl/main/install.sh -o installOpenAgentControl.sh
. installOpenAgentControl.sh
cd ~/.config/opencode
cp env.example .env
nano .env
opencode --agent OpenAgent
For next usages:
cd repo
opencode --agent OpenAgent
Setup Software Projects#
From within OpenCode /Init
Adapt .opencode/context/project-intelligence.md