Skip to content

Commit 18ecf90

Browse files
Michael Vincent PattersonMichael Vincent Patterson
authored andcommitted
Add Ray Dashboard module
1 parent d212de4 commit 18ecf90

File tree

10 files changed

+153
-0
lines changed

10 files changed

+153
-0
lines changed

modules/ray-dashboard/.DS_Store

6 KB
Binary file not shown.
6 KB
Binary file not shown.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# Ray Coder Module
2+
3+
This Coder module provides easy integration of Ray.io distributed computing framework into your Coder workspaces. It automatically sets up Ray with a dashboard interface and creates a dedicated Python virtual environment.
4+
5+
## Features
6+
7+
- 🚀 **Ray Dashboard**: Web-based interface for monitoring Ray clusters
8+
- 🐍 **Python Virtual Environment**: Isolated environment with Ray and dependencies
9+
- 📊 **Jupyter Integration**: Optional Jupyter kernel with Ray support
10+
- ⚙️ **Customizable**: Configurable Ray extras, packages, and settings
11+
- 🔧 **Auto-setup**: Automatic Ray installation and dashboard startup
12+
13+
## Usage
14+
15+
### Basic Usage
16+
17+
```hcl
18+
module "ray" {
19+
source = "registry.coder.com/modules/ray/coder"
20+
version = "1.0.0"
21+
agent_id = coder_agent.main.id
22+
}
23+
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
resource "coder_app" "ray-dashboard" {
2+
agent_id = var.agent_id
3+
slug = var.slug
4+
display_name = var.display_name
5+
icon = var.icon
6+
url = "http://localhost:${var.port}"
7+
subdomain = var.subdomain
8+
share = var.share
9+
10+
healthcheck {
11+
url = "http://localhost:${var.port}"
12+
interval = var.healthcheck_interval
13+
threshold = var.healthcheck_threshold
14+
}
15+
}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"display_name": "Ray.io",
3+
"description": "Adds Ray distributed computing framework with dashboard integration to Coder workspaces",
4+
"icon_url": "https://raw.githubusercontent.com/ray-project/ray/master/doc/source/images/ray_logo.png",
5+
"maintainer": {
6+
"name": "Ray Coder Module Contributors",
7+
"email": "",
8+
"url": ""
9+
},
10+
"tags": [
11+
"ray",
12+
"distributed-computing",
13+
"machine-learning",
14+
"python",
15+
"jupyter",
16+
"dashboard"
17+
],
18+
"readme_url": "README.md",
19+
"url": "",
20+
"verified": false
21+
}
22+
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
display_name: "Ray Dashboard"
2+
description: "Ray Dashboard integration for Coder workspaces"
3+
icon_url: "https://raw.githubusercontent.com/ray-project/ray/master/doc/source/images/ray_logo.png"
4+
maintainers:
5+
- github: "michaelvp411"
6+
name: "Michael Vincent Patterson"
7+
tags:
8+
- "ray"
9+
- "dashboard"
10+
- "distributed-computing"
11+
verified: false
12+
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
output "ray_dashboard_url" {
2+
description = "The URL for accessing the Ray Dashboard"
3+
value = coder_app.ray-dashboard.url
4+
}
5+
6+
output "ray_dashboard_app_id" {
7+
description = "The ID of the Ray Dashboard app resource"
8+
value = coder_app.ray-dashboard.id
9+
}
10+
11+
output "ray_port" {
12+
description = "The port number used by Ray Dashboard"
13+
value = var.port
14+
}
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
variable "agent_id" {
2+
description = "The ID of the Coder agent to install Ray on"
3+
type = string
4+
}
5+
6+
variable "slug" {
7+
description = "The slug for the Ray Dashboard app"
8+
type = string
9+
default = "ray-dashboard"
10+
}
11+
12+
variable "display_name" {
13+
description = "The display name for the Ray Dashboard app"
14+
type = string
15+
default = "Ray Dashboard"
16+
}
17+
18+
variable "icon" {
19+
description = "The icon URL for the Ray Dashboard app"
20+
type = string
21+
default = "https://raw.githubusercontent.com/ray-project/ray/master/doc/source/images/ray_logo.png"
22+
}
23+
24+
variable "port" {
25+
description = "The port number for the Ray Dashboard"
26+
type = number
27+
default = 8265
28+
}
29+
30+
variable "subdomain" {
31+
description = "Whether to use a subdomain for the Ray Dashboard"
32+
type = bool
33+
default = true
34+
}
35+
36+
variable "share" {
37+
description = "The sharing level for the Ray Dashboard app"
38+
type = string
39+
default = "owner"
40+
}
41+
42+
variable "healthcheck_interval" {
43+
description = "Health check interval in seconds"
44+
type = number
45+
default = 5
46+
}
47+
48+
variable "healthcheck_threshold" {
49+
description = "Health check threshold"
50+
type = number
51+
default = 10
52+
}
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
terraform {
2+
required_version = ">= 1.0"
3+
4+
required_providers {
5+
coder = {
6+
source = "coder/coder"
7+
version = ">= 0.21.0"
8+
}
9+
}
10+
}
11+
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
versions:
2+
- ref: "v1.0.0"
3+
published_at: "2025-09-18"
4+

0 commit comments

Comments
 (0)