From 2fb3b09591fa203fbb5489995beaa9b215a7b068 Mon Sep 17 00:00:00 2001 From: Phorcys <57866459+phorcys420@users.noreply.github.com> Date: Sat, 16 Nov 2024 16:39:48 +0000 Subject: [PATCH] feat: add code-server and jetbrains gateway modules --- examples/templates/digitalocean-linux/main.tf | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/examples/templates/digitalocean-linux/main.tf b/examples/templates/digitalocean-linux/main.tf index 89665c120f5e9..5e370ae5e47e9 100644 --- a/examples/templates/digitalocean-linux/main.tf +++ b/examples/templates/digitalocean-linux/main.tf @@ -264,6 +264,38 @@ resource "coder_agent" "main" { } } +# See https://registry.coder.com/modules/code-server +module "code-server" { + count = data.coder_workspace.me.start_count + source = "registry.coder.com/modules/code-server/coder" + + # This ensures that the latest version of the module gets downloaded, you can also pin the module version to prevent breaking changes in production. + version = ">= 1.0.0" + + agent_id = coder_agent.main.id + order = 1 +} + +# See https://registry.coder.com/modules/jetbrains-gateway +module "jetbrains_gateway" { + count = data.coder_workspace.me.start_count + source = "registry.coder.com/modules/jetbrains-gateway/coder" + + # JetBrains IDEs to make available for the user to select + jetbrains_ides = ["IU", "PY", "WS", "PS", "RD", "CL", "GO", "RM"] + default = "IU" + + # Default folder to open when starting a JetBrains IDE + folder = "/home/coder" + + # This ensures that the latest version of the module gets downloaded, you can also pin the module version to prevent breaking changes in production. + version = ">= 1.0.0" + + agent_id = coder_agent.main.id + agent_name = "main" + order = 2 +} + resource "digitalocean_volume" "home_volume" { region = data.coder_parameter.region.value name = "coder-${data.coder_workspace.me.id}-home"