Skip to content

Commit 2349eba

Browse files
chore: restructure and clean up README
1 parent 17ee696 commit 2349eba

File tree

1 file changed

+63
-49
lines changed
  • registry/BenraouaneSoufiane/modules/rustdesk

1 file changed

+63
-49
lines changed
Lines changed: 63 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,80 +1,94 @@
11
---
2-
display_name: Rustdesk
3-
description: Create desktop environment & run rustdesk in your workspace
2+
display_name: RustDesk
3+
description: Create a desktop environment and run RustDesk in your workspace
44
icon: ../../../../.icons/rustdesk.svg
55
verified: false
66
tags: [rustdesk, rdp, vm]
77
---
88

9-
# RustDesk Coder Module
9+
# RustDesk
1010

11-
This is the basic Coder's rustdesk module that installs minimal desktop environment (xfce) & launches the rustdesk within your workspace
11+
Installs a minimal desktop environment (XFCE) and launches RustDesk within your workspace to provide remote desktop access. The module outputs the RustDesk ID and password needed to connect from external RustDesk clients.
1212

13-
---
13+
```tf
14+
module "rustdesk" {
15+
count = data.coder_workspace.me.start_count
16+
source = "registry.coder.com/BenraouaneSoufiane/rustdesk/coder"
17+
version = "1.0.0"
18+
agent_id = coder_agent.example.id
19+
}
20+
```
1421

1522
## Features
1623

17-
- Installs RustDesk & launches it in GUI not with black screen
18-
- Outputs the RustDesk ID and password
19-
- Automatically launches RustDesk on workspace start
20-
- Provides an external app link to the [RustDesk web client](https://rustdesk.com/web)
21-
22-
---
23-
24-
## Usage
24+
- Automatically installs XFCE desktop environment
25+
- Downloads and configures RustDesk
26+
- Outputs RustDesk ID and password for easy connection
27+
- Provides external app link to RustDesk web client for browser-based access
28+
- Starts virtual display (Xvfb) with customizable resolution
29+
- Customizable screen resolution and RustDesk version
2530

26-
### Prerequisites
31+
## Requirements
2732

2833
- Coder v2.5 or higher
29-
- A workspace agent compatible with Linux and `apt` package manager
30-
- Root scope (to install desktop environment, rustdesk & execute rustdesk --password "somepassword", because rustdesk cli does not provide a way to get the password else setup in advance, the command rustdesk --password "somepassword" only for root users)
31-
32-
---
34+
- Linux workspace with `apt`, `dnf`, or `yum` package manager
35+
- Root privileges (required for desktop environment installation and RustDesk password configuration)
3336

34-
### Quickstart
37+
## Examples
3538

36-
1. Add the module to your [Coder Terraform workspace](https://registry.coder.com)
37-
2. Include it in your `main.tf`:
39+
### Basic setup
3840

3941
```tf
4042
module "rustdesk" {
41-
source = "registry.coder.com/BenraouaneSoufiane/rustdesk/BenraouaneSoufiane"
42-
agent_id = var.agent_id
43+
count = data.coder_workspace.me.start_count
44+
source = "registry.coder.com/BenraouaneSoufiane/rustdesk/coder"
45+
version = "1.0.0"
46+
agent_id = coder_agent.example.id
4347
}
4448
```
4549

46-
Also add this within resource "docker_container" "workspace":
50+
### Custom configuration
4751

4852
```tf
49-
privileged = true
50-
user = "root"
51-
network_mode = "host"
52-
ports {
53-
internal = 21115
54-
external = 21115
55-
}
56-
ports {
57-
internal = 21116
58-
external = 21116
59-
}
60-
ports {
61-
internal = 21118
62-
external = 21118
63-
}
64-
ports {
65-
internal = 21119
66-
external = 21119
53+
module "rustdesk" {
54+
count = data.coder_workspace.me.start_count
55+
source = "registry.coder.com/BenraouaneSoufiane/rustdesk/coder"
56+
version = "1.0.0"
57+
agent_id = coder_agent.example.id
58+
rustdesk_password = "mycustompass"
59+
xvfb_resolution = "1920x1080x24"
60+
rustdesk_version = "1.4.0"
6761
}
6862
```
6963

70-
Also you can customize the rustdesk version, virtual screen dimensions & the pass
64+
### Docker container configuration
65+
66+
When using with Docker, add the following to your `docker_container` resource:
7167

7268
```tf
73-
module "rustdesk" {
74-
source = "registry.coder.com/BenraouaneSoufiane/rustdesk/BenraouaneSoufiane"
75-
agent_id = var.agent_id
76-
rustdesk_password = "mycustompass"
77-
xvfb_resolution = "1920x1080x24"
78-
rustdesk_version = "1.4.0"
69+
resource "docker_container" "workspace" {
70+
# ... other configuration ...
71+
72+
privileged = true
73+
user = "root"
74+
network_mode = "host"
75+
76+
ports {
77+
internal = 21115
78+
external = 21115
79+
}
80+
ports {
81+
internal = 21116
82+
external = 21116
83+
}
84+
ports {
85+
internal = 21118
86+
external = 21118
87+
}
88+
ports {
89+
internal = 21119
90+
external = 21119
91+
}
7992
}
8093
```
94+

0 commit comments

Comments
 (0)