Skip to content

Commit 5f7bec4

Browse files
committed
docs: simplify README and add NOTES.md for opencode
- Simplify main README to index with links to feature documentation - Add src/opencode/NOTES.md with volume mount details
1 parent ba24317 commit 5f7bec4

2 files changed

Lines changed: 23 additions & 104 deletions

File tree

README.md

Lines changed: 8 additions & 104 deletions
Original file line numberDiff line numberDiff line change
@@ -1,110 +1,14 @@
11
# Dev Container Features
22

3-
This repository provides a collection of [dev container Features](https://containers.dev/implementors/features/) for use in dev containers and GitHub Codespaces. Each Feature is independently versioned and published to GitHub Container Registry (GHCR) following the [dev container Feature distribution specification](https://containers.dev/implementors/features-distribution/).
3+
This repository provides a collection of [dev container Features](https://containers.dev/implementors/features/) for use in dev containers and GitHub Codespaces. Each Feature is independently versioned and published to GitHub Container Registry (GHCR).
44

5-
## Feature: `agency-agents`
5+
## Features
66

7-
Adds the [msitarzewski/agency-agents](https://github.com/msitarzewski/agency-agents) agent set to your dev container. During the container build it:
7+
| Feature | Description | Documentation |
8+
|---------|-------------|---------------|
9+
| `opencode` | AI coding agent CLI | [src/opencode/README.md](src/opencode/README.md) |
10+
| `agency-agents` | AI agent set for Cursor/Copilot | [src/agency-agents/README.md](src/agency-agents/README.md) |
811

9-
1. Downloads the upstream repository as a ZIP archive.
10-
2. Runs `scripts/convert.sh` to prepare the agents.
11-
3. Runs `scripts/install.sh --no-interactive --parallel` when `tool=auto` (default), or `scripts/install.sh --tool <tool> --no-interactive` for explicit tool mode.
12+
---
1213

13-
The feature only installs the upstream agent files for the selected tool(s). It does not create or modify workspace `AGENTS.md` files.
14-
15-
Official website: [agencyagents.dev](https://agencyagents.dev)
16-
17-
### Usage
18-
19-
```jsonc
20-
{
21-
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
22-
"features": {
23-
"ghcr.io/YOUR_GITHUB_USER/agency-agents/agency-agents:0": {}
24-
}
25-
}
26-
```
27-
28-
To install for a specific tool, pass the `tool` option:
29-
30-
```jsonc
31-
{
32-
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
33-
"features": {
34-
"ghcr.io/YOUR_GITHUB_USER/agency-agents/agency-agents:0": {
35-
"tool": "cursor"
36-
}
37-
}
38-
}
39-
```
40-
41-
### Options
42-
43-
| Option | Type | Default | Description |
44-
|--------|--------|------------|---------------------------------------------------------------------|
45-
| `tool` | string | `auto` | `auto` runs `install.sh --no-interactive --parallel`; otherwise uses `--tool <tool>` (e.g. `copilot`, `cursor`). |
46-
47-
### Credits
48-
49-
The agents installed by this feature come from the [msitarzewski/agency-agents](https://github.com/msitarzewski/agency-agents) repository. All credit for the agent definitions, `convert.sh`, and `install.sh` scripts belongs to the upstream project and its contributors.
50-
51-
Project website: [agencyagents.dev](https://agencyagents.dev)
52-
53-
This repository only wraps that upstream work as a dev container Feature for easier, reproducible installation inside dev containers.
54-
55-
## Feature: `opencode`
56-
57-
Installs the [opencode](https://opencode.ai) AI coding agent CLI and ensures volume-mounted data directories are owned by the correct user. During the container build it:
58-
59-
1. Downloads and runs the opencode installer via `curl -fsSL https://opencode.ai/install | bash -s -- --no-modify-path`.
60-
2. Creates a symlink at `/usr/local/bin/opencode` so the CLI is available on `PATH`.
61-
3. Installs a `/usr/local/bin/opencode-fix-permissions` script that fixes ownership of volume-mounted data directories.
62-
63-
The feature runs `opencode-fix-permissions` as a `postStartCommand` to ensure the `config`, `data`, and `state` directories under `~/.opencode` are owned by the dev container user.
64-
65-
Official documentation: [opencode.ai](https://opencode.ai)
66-
67-
### Usage
68-
69-
```jsonc
70-
{
71-
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
72-
"features": {
73-
"ghcr.io/YOUR_GITHUB_USER/devcontainer-features/opencode:0": {}
74-
}
75-
}
76-
```
77-
78-
To specify the username for volume ownership fixes, pass the `username` option:
79-
80-
```jsonc
81-
{
82-
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
83-
"features": {
84-
"ghcr.io/YOUR_GITHUB_USER/devcontainer-features/opencode:0": {
85-
"username": "vscode"
86-
}
87-
}
88-
}
89-
```
90-
91-
### Options
92-
93-
| Option | Type | Default | Description |
94-
|------------|--------|---------|----------------------------------------------------------------|
95-
| `username` | string | `""` | Username to own the `~/.opencode` volume-mounted directories. |
96-
| `version` | string | `""` | Specific version to install (e.g. `1.3.17`). Empty = latest. |
97-
98-
### Volume Mounts
99-
100-
Opencode stores its configuration, data, and state under `~/.opencode` in three subdirectories:
101-
102-
- `config` – configuration files
103-
- `data` – project data and caches
104-
- `state` – runtime state
105-
106-
When these directories are volume-mounted into the container, they may be owned by `root` depending on how the volumes are created. The `opencode-fix-permissions` script runs on container start to `chown` these directories to the specified user, ensuring opencode can read and write them without permission errors.
107-
108-
### Shared Volumes Between Projects
109-
110-
If you share the same `~/.opencode` volume mounts across multiple projects, be aware that opencode's state and data will be shared as well. This can be useful for preserving context between projects, but may also cause unexpected behaviour if projects have conflicting configurations. Consider using separate volume mounts per project if isolation is needed.
14+
For detailed usage instructions, see each feature's README.

src/opencode/NOTES.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# OpenCode Feature - Additional Notes
2+
3+
## Volume Mounts
4+
5+
Opencode stores its configuration, data, and state under `~/.opencode` in three subdirectories:
6+
7+
- `config` – configuration files
8+
- `data` – project data and caches
9+
- `state` – runtime state
10+
11+
When these directories are volume-mounted into the container, they may be owned by `root` depending on how the volumes are created. The `opencode-fix-permissions` script runs on container start to `chown` these directories to the specified user, ensuring opencode can read and write them without permission errors.
12+
13+
## Shared Volumes Between Projects
14+
15+
If you share the same `~/.opencode` volume mounts across multiple projects, be aware that opencode's state and data will be shared as well. This can be useful for preserving context between projects, but may also cause unexpected behaviour if projects have conflicting configurations. Consider using separate volume mounts per project if isolation is needed.

0 commit comments

Comments
 (0)