Skip to content

Commit f724c39

Browse files
committed
Merge branch 'sourcegraph-amp-module' of github.com:Harsh9485/registry into sourcegraph-amp-module
2 parents a42eee5 + 1690b53 commit f724c39

File tree

14 files changed

+462
-56
lines changed

14 files changed

+462
-56
lines changed

.github/workflows/deploy-registry.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
name: deploy-registry
22

33
on:
4+
schedule:
5+
# Runs at 02:30 UTC Monday through Friday
6+
- cron: "30 2 * * 1-5"
47
push:
58
tags:
69
# Matches release/<namespace>/<resource_name>/<semantic_version>

registry/coder/modules/agentapi/README.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,22 @@
11
---
22
display_name: AgentAPI
3-
description: Building block for modules that need to run an agentapi server
3+
description: Building block for modules that need to run an AgentAPI server
44
icon: ../../../../.icons/coder.svg
55
verified: true
6-
tags: [internal]
6+
tags: [internal, library]
77
---
88

99
# AgentAPI
1010

11-
The AgentAPI module is a building block for modules that need to run an agentapi server. It is intended primarily for internal use by Coder to create modules compatible with Tasks.
11+
> [!CAUTION]
12+
> We do not recommend using this module directly. Instead, please consider using one of our [Tasks-compatible AI agent modules](https://registry.coder.com/modules?search=tag%3Atasks).
1213
13-
We do not recommend using this module directly. Instead, please consider using one of our [Tasks-compatible AI agent modules](https://registry.coder.com/modules?search=tag%3Atasks).
14+
The AgentAPI module is a building block for modules that need to run an AgentAPI server. It is intended primarily for internal use by Coder to create modules compatible with Tasks.
1415

1516
```tf
1617
module "agentapi" {
1718
source = "registry.coder.com/coder/agentapi/coder"
18-
version = "1.0.1"
19+
version = "1.0.2"
1920
2021
agent_id = var.agent_id
2122
web_app_slug = local.app_slug
@@ -50,4 +51,4 @@ module "agentapi" {
5051

5152
## For module developers
5253

53-
For a complete example of how to use this module, see the [goose module](https://github.com/coder/registry/blob/main/registry/coder/modules/goose/main.tf).
54+
For a complete example of how to use this module, see the [Goose module](https://github.com/coder/registry/blob/main/registry/coder/modules/goose/main.tf).

registry/coder/modules/aider/README.md

Lines changed: 8 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Run [Aider](https://aider.chat) AI pair programming in your workspace. This modu
1313
```tf
1414
module "aider" {
1515
source = "registry.coder.com/coder/aider/coder"
16-
version = "1.1.1"
16+
version = "1.1.2"
1717
agent_id = coder_agent.example.id
1818
}
1919
```
@@ -30,29 +30,8 @@ module "aider" {
3030

3131
## Module Parameters
3232

33-
| Parameter | Description | Type | Default |
34-
| ---------------------------------- | -------------------------------------------------------------------------- | -------- | ------------------- |
35-
| `agent_id` | The ID of a Coder agent (required) | `string` | - |
36-
| `folder` | The folder to run Aider in | `string` | `/home/coder` |
37-
| `install_aider` | Whether to install Aider | `bool` | `true` |
38-
| `aider_version` | The version of Aider to install | `string` | `"latest"` |
39-
| `use_screen` | Whether to use screen for running Aider in the background | `bool` | `true` |
40-
| `use_tmux` | Whether to use tmux instead of screen for running Aider in the background | `bool` | `false` |
41-
| `session_name` | Name for the persistent session (screen or tmux) | `string` | `"aider"` |
42-
| `order` | Position of the app in the UI presentation | `number` | `null` |
43-
| `icon` | The icon to use for the app | `string` | `"/icon/aider.svg"` |
44-
| `experiment_report_tasks` | Whether to enable task reporting | `bool` | `true` |
45-
| `system_prompt` | System prompt for instructing Aider on task reporting and behavior | `string` | See default in code |
46-
| `task_prompt` | Task prompt to use with Aider | `string` | `""` |
47-
| `ai_provider` | AI provider to use with Aider (openai, anthropic, azure, etc.) | `string` | `"anthropic"` |
48-
| `ai_model` | AI model to use (can use Aider's built-in aliases like "sonnet", "4o") | `string` | `"sonnet"` |
49-
| `ai_api_key` | API key for the selected AI provider | `string` | `""` |
50-
| `custom_env_var_name` | Custom environment variable name when using custom provider | `string` | `""` |
51-
| `experiment_pre_install_script` | Custom script to run before installing Aider | `string` | `null` |
52-
| `experiment_post_install_script` | Custom script to run after installing Aider | `string` | `null` |
53-
| `experiment_additional_extensions` | Additional extensions configuration in YAML format to append to the config | `string` | `null` |
54-
55-
> **Note**: `use_screen` and `use_tmux` cannot both be enabled at the same time. By default, `use_screen` is set to `true` and `use_tmux` is set to `false`.
33+
> [!NOTE]
34+
> The `use_screen` and `use_tmux` parameters cannot both be enabled at the same time. By default, `use_screen` is set to `true` and `use_tmux` is set to `false`.
5635
5736
## Usage Examples
5837

@@ -68,7 +47,7 @@ variable "anthropic_api_key" {
6847
module "aider" {
6948
count = data.coder_workspace.me.start_count
7049
source = "registry.coder.com/coder/aider/coder"
71-
version = "1.1.1"
50+
version = "1.1.2"
7251
agent_id = coder_agent.example.id
7352
ai_api_key = var.anthropic_api_key
7453
}
@@ -93,7 +72,7 @@ variable "openai_api_key" {
9372
module "aider" {
9473
count = data.coder_workspace.me.start_count
9574
source = "registry.coder.com/coder/aider/coder"
96-
version = "1.1.1"
75+
version = "1.1.2"
9776
agent_id = coder_agent.example.id
9877
use_tmux = true
9978
ai_provider = "openai"
@@ -114,7 +93,7 @@ variable "custom_api_key" {
11493
module "aider" {
11594
count = data.coder_workspace.me.start_count
11695
source = "registry.coder.com/coder/aider/coder"
117-
version = "1.1.1"
96+
version = "1.1.2"
11897
agent_id = coder_agent.example.id
11998
ai_provider = "custom"
12099
custom_env_var_name = "MY_CUSTOM_API_KEY"
@@ -131,7 +110,7 @@ You can extend Aider's capabilities by adding custom extensions:
131110
module "aider" {
132111
count = data.coder_workspace.me.start_count
133112
source = "registry.coder.com/coder/aider/coder"
134-
version = "1.1.1"
113+
version = "1.1.2"
135114
agent_id = coder_agent.example.id
136115
ai_api_key = var.anthropic_api_key
137116
@@ -210,7 +189,7 @@ data "coder_parameter" "ai_prompt" {
210189
module "aider" {
211190
count = data.coder_workspace.me.start_count
212191
source = "registry.coder.com/coder/aider/coder"
213-
version = "1.1.1"
192+
version = "1.1.2"
214193
agent_id = coder_agent.example.id
215194
ai_api_key = var.anthropic_api_key
216195
task_prompt = data.coder_parameter.ai_prompt.value
@@ -308,7 +287,3 @@ If you encounter issues:
308287
3. **Browser mode issues**: If the browser interface doesn't open, check that you're accessing it from a machine that can reach your Coder workspace
309288

310289
For more information on using Aider, see the [Aider documentation](https://aider.chat/docs/).
311-
312-
```
313-
314-
```

registry/coder/modules/amazon-q/README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,9 @@ Run [Amazon Q](https://aws.amazon.com/q/) in your workspace to access Amazon's A
1313
```tf
1414
module "amazon-q" {
1515
source = "registry.coder.com/coder/amazon-q/coder"
16-
version = "1.1.1"
16+
version = "1.1.2"
1717
agent_id = coder_agent.example.id
18+
1819
# Required: see below for how to generate
1920
experiment_auth_tarball = var.amazon_q_auth_tarball
2021
}
@@ -81,7 +82,7 @@ module "amazon-q" {
8182
```tf
8283
module "amazon-q" {
8384
source = "registry.coder.com/coder/amazon-q/coder"
84-
version = "1.1.1"
85+
version = "1.1.2"
8586
agent_id = coder_agent.example.id
8687
experiment_auth_tarball = var.amazon_q_auth_tarball
8788
experiment_use_tmux = true
@@ -93,7 +94,7 @@ module "amazon-q" {
9394
```tf
9495
module "amazon-q" {
9596
source = "registry.coder.com/coder/amazon-q/coder"
96-
version = "1.1.1"
97+
version = "1.1.2"
9798
agent_id = coder_agent.example.id
9899
experiment_auth_tarball = var.amazon_q_auth_tarball
99100
experiment_report_tasks = true
@@ -105,7 +106,7 @@ module "amazon-q" {
105106
```tf
106107
module "amazon-q" {
107108
source = "registry.coder.com/coder/amazon-q/coder"
108-
version = "1.1.1"
109+
version = "1.1.2"
109110
agent_id = coder_agent.example.id
110111
experiment_auth_tarball = var.amazon_q_auth_tarball
111112
experiment_pre_install_script = "echo Pre-install!"

registry/coder/modules/claude-code/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Run the [Claude Code](https://docs.anthropic.com/en/docs/agents-and-tools/claude
1313
```tf
1414
module "claude-code" {
1515
source = "registry.coder.com/coder/claude-code/coder"
16-
version = "2.0.3"
16+
version = "2.0.4"
1717
agent_id = coder_agent.example.id
1818
folder = "/home/coder"
1919
install_claude_code = true
@@ -84,7 +84,7 @@ resource "coder_agent" "main" {
8484
module "claude-code" {
8585
count = data.coder_workspace.me.start_count
8686
source = "registry.coder.com/coder/claude-code/coder"
87-
version = "2.0.3"
87+
version = "2.0.4"
8888
agent_id = coder_agent.example.id
8989
folder = "/home/coder"
9090
install_claude_code = true
@@ -102,7 +102,7 @@ Run Claude Code as a standalone app in your workspace. This will install Claude
102102
```tf
103103
module "claude-code" {
104104
source = "registry.coder.com/coder/claude-code/coder"
105-
version = "2.0.3"
105+
version = "2.0.4"
106106
agent_id = coder_agent.example.id
107107
folder = "/home/coder"
108108
install_claude_code = true

registry/coder/modules/claude-code/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ variable "install_agentapi" {
100100
variable "agentapi_version" {
101101
type = string
102102
description = "The version of AgentAPI to install."
103-
default = "v0.2.3"
103+
default = "v0.3.0"
104104
}
105105

106106
locals {

registry/coder/modules/hcp-vault-secrets/README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ tags: [integration, vault, hashicorp, hvs]
1515
>
1616
> **Use these Coder registry modules instead:**
1717
>
18-
> - **[vault-token](https://registry.coder.com/modules/vault-token)** - Connect to Vault using access tokens
19-
> - **[vault-jwt](https://registry.coder.com/modules/vault-jwt)** - Connect to Vault using JWT/OIDC authentication
20-
> - **[vault-github](https://registry.coder.com/modules/vault-github)** - Connect to Vault using GitHub authentication
18+
> - **[vault-token](https://registry.coder.com/modules/coder/vault-token)** - Connect to Vault using access tokens
19+
> - **[vault-jwt](https://registry.coder.com/modules/coder/vault-jwt)** - Connect to Vault using JWT/OIDC authentication
20+
> - **[vault-github](https://registry.coder.com/modules/coder/vault-github)** - Connect to Vault using GitHub authentication
2121
>
2222
> These modules work with both self-hosted Vault and HCP Vault Dedicated. For migration help, see the [official HashiCorp announcement](https://developer.hashicorp.com/hcp/docs/vault-secrets/end-of-sale-announcement).
2323
@@ -26,7 +26,7 @@ This module lets you fetch all or selective secrets from a [HCP Vault Secrets](h
2626
```tf
2727
module "vault" {
2828
source = "registry.coder.com/coder/hcp-vault-secrets/coder"
29-
version = "1.0.33"
29+
version = "1.0.34"
3030
agent_id = coder_agent.example.id
3131
app_name = "demo-app"
3232
project_id = "aaa-bbb-ccc"
@@ -52,7 +52,7 @@ To fetch all secrets from the HCP Vault Secrets app, skip the `secrets` input.
5252
```tf
5353
module "vault" {
5454
source = "registry.coder.com/coder/hcp-vault-secrets/coder"
55-
version = "1.0.33"
55+
version = "1.0.34"
5656
agent_id = coder_agent.example.id
5757
app_name = "demo-app"
5858
project_id = "aaa-bbb-ccc"
@@ -66,7 +66,7 @@ To fetch selective secrets from the HCP Vault Secrets app, set the `secrets` inp
6666
```tf
6767
module "vault" {
6868
source = "registry.coder.com/coder/hcp-vault-secrets/coder"
69-
version = "1.0.33"
69+
version = "1.0.34"
7070
agent_id = coder_agent.example.id
7171
app_name = "demo-app"
7272
project_id = "aaa-bbb-ccc"
@@ -81,7 +81,7 @@ Set `client_id` and `client_secret` as module inputs.
8181
```tf
8282
module "vault" {
8383
source = "registry.coder.com/coder/hcp-vault-secrets/coder"
84-
version = "1.0.33"
84+
version = "1.0.34"
8585
agent_id = coder_agent.example.id
8686
app_name = "demo-app"
8787
project_id = "aaa-bbb-ccc"

registry/coder/modules/jupyter-notebook/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ A module that adds Jupyter Notebook in your Coder template.
1616
module "jupyter-notebook" {
1717
count = data.coder_workspace.me.start_count
1818
source = "registry.coder.com/coder/jupyter-notebook/coder"
19-
version = "1.1.1"
19+
version = "1.2.0"
2020
agent_id = coder_agent.example.id
2121
}
2222
```

registry/coder/modules/jupyter-notebook/main.tf

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,27 @@ variable "group" {
4848
default = null
4949
}
5050

51+
variable "requirements_path" {
52+
type = string
53+
description = "The path to requirements.txt with packages to preinstall"
54+
default = ""
55+
}
56+
57+
variable "pip_install_extra_packages" {
58+
type = string
59+
description = "List of extra packages to preinstall (example: numpy==1.26.4 pandas matplotlib<4 scikit-learn)"
60+
default = ""
61+
}
62+
5163
resource "coder_script" "jupyter-notebook" {
5264
agent_id = var.agent_id
5365
display_name = "jupyter-notebook"
5466
icon = "/icon/jupyter.svg"
5567
script = templatefile("${path.module}/run.sh", {
5668
LOG_PATH : var.log_path,
57-
PORT : var.port
69+
PORT : var.port,
70+
REQUIREMENTS_PATH : var.requirements_path,
71+
PIP_INSTALL_EXTRA_PACKAGES : var.pip_install_extra_packages
5872
})
5973
run_on_start = true
6074
}

registry/coder/modules/jupyter-notebook/run.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,24 @@ else
2020
echo "🥳 jupyter-notebook is already installed\n\n"
2121
fi
2222

23+
# Install packages selected with REQUIREMENTS_PATH
24+
if [ -n "${REQUIREMENTS_PATH}" ]; then
25+
if [ -f "${REQUIREMENTS_PATH}" ]; then
26+
echo "📄 Installing packages from ${REQUIREMENTS_PATH}..."
27+
pipx -q runpip notebook install -r "${REQUIREMENTS_PATH}"
28+
echo "🥳 Packages from ${REQUIREMENTS_PATH} have been installed\n\n"
29+
else
30+
echo "⚠️ REQUIREMENTS_PATH is set to '${REQUIREMENTS_PATH}' but the file does not exist!\n\n"
31+
fi
32+
fi
33+
34+
# Install packages selected with PIP_INSTALL_EXTRA_PACKAGES
35+
if [ -n "${PIP_INSTALL_EXTRA_PACKAGES}" ]; then
36+
echo "📦 Installing additional packages: ${PIP_INSTALL_EXTRA_PACKAGES}"
37+
pipx -q runpip notebook install ${PIP_INSTALL_EXTRA_PACKAGES}
38+
echo "🥳 Additional packages have been installed\n\n"
39+
fi
40+
2341
echo "👷 Starting jupyter-notebook in background..."
2442
echo "check logs at ${LOG_PATH}"
2543
$HOME/.local/bin/jupyter-notebook --NotebookApp.ip='0.0.0.0' --ServerApp.port=${PORT} --no-browser --ServerApp.token='' --ServerApp.password='' > ${LOG_PATH} 2>&1 &

0 commit comments

Comments
 (0)