Just Opencode in a container with some tools.
podman run -it --rm \
-v "$(pwd):/work$(pwd):Z" \
-w "/work$(pwd)" \
-v "$HOME/.local/share/opencode:/root/.local/share/opencode:Z" \
-v "$HOME/.local/state/opencode:/root/.local/state/opencode:Z" \
-v "$HOME/.config/opencode:/root/.config/opencode:Z" \
-v "$HOME/.cache/opencode:/root/.cache/opencode:Z" \
-v /tmp/.X11-unix:/tmp/.X11-unix:ro \
-v $HOME/.Xauthority:/root/.Xauthority:ro \
-e DISPLAY=$DISPLAY \
-e OPENCODE_DISABLE_AUTOUPDATE=true \
-e GIT_COMMITTER_NAME="Your Name" \
-e GIT_COMMITTER_EMAIL="your@email.com" \
-e EDITOR="gnome-text-editor" \
-e ADW_DEBUG_COLOR_SCHEME="prefer-dark" \
--security-opt=no-new-privileges \
ghcr.io/randommm/opencodeYou might need to create the dirs first:
mkdir -p \
$HOME/.local/share/opencode \
$HOME/.local/state/opencode \
$HOME/.config/opencode \
$HOME/.cache/opencodeYou might also want to add more bind to you podman command, e.g.:
-v $HOME/.cache/uv:/root/.cache/uv \
-v $HOME/.local/share/uv:/root/.local/share/uv \
-v $HOME/.cache/pip:/root/.cache/pip \
-v $HOME/.cache/huggingface:/root/.cache/huggingface \These lines were added to enable clipboard support (and to use gnome-text-editor when calling /editor):
-v /tmp/.X11-unix:/tmp/.X11-unix:ro \
-v $HOME/.Xauthority:/root/.Xauthority:ro \
-e DISPLAY=$DISPLAY \If you don't use them, you will need an OSC52 compliant terminal for clipboard to work, e.g.: kitty, konsole, ghostty.