Florian Bittner e95d90d9e8
fix(jetbrains-gateway) add agent id to url (#167)
## Description

<!-- Briefly describe what this PR does and why -->
This PR adds the agent_id parameter to the url so jetbrains-gateway can
handle multiple agents.

---

## Type of Change

- [ ] New module
- [ ] Bug fix
- [x] Feature/enhancement
- [ ] Documentation
- [ ] Other

---

## Testing & Validation

- [x] Tests pass (`bun test`)
- [ ] Code formatted (`bun run fmt`)
- [ ] Changes tested locally

---

## Related Issues

<!-- Link related issues or write "None" if not applicable -->

Closes #166
2025-07-03 22:45:32 +05:00
..

display_name description icon maintainer_github verified tags
JetBrains Gateway Add a one-click button to launch JetBrains Gateway IDEs in the dashboard. ../../../../.icons/gateway.svg coder true
ide
jetbrains
parameter
gateway

JetBrains Gateway

This module adds a JetBrains Gateway Button to open any workspace with a single click.

JetBrains recommends a minimum of 4 CPU cores and 8GB of RAM. Consult the JetBrains documentation to confirm other system requirements.

module "jetbrains_gateway" {
  count          = data.coder_workspace.me.start_count
  source         = "registry.coder.com/coder/jetbrains-gateway/coder"
  version        = "1.2.1"
  agent_id       = coder_agent.example.id
  folder         = "/home/coder/example"
  jetbrains_ides = ["CL", "GO", "IU", "PY", "WS"]
  default        = "GO"
}

JetBrains Gateway IDes list

Examples

Add GoLand and WebStorm as options with the default set to GoLand

module "jetbrains_gateway" {
  count          = data.coder_workspace.me.start_count
  source         = "registry.coder.com/coder/jetbrains-gateway/coder"
  version        = "1.2.1"
  agent_id       = coder_agent.example.id
  folder         = "/home/coder/example"
  jetbrains_ides = ["GO", "WS"]
  default        = "GO"
}

Use the latest version of each IDE

module "jetbrains_gateway" {
  count          = data.coder_workspace.me.start_count
  source         = "registry.coder.com/coder/jetbrains-gateway/coder"
  version        = "1.2.1"
  agent_id       = coder_agent.example.id
  folder         = "/home/coder/example"
  jetbrains_ides = ["IU", "PY"]
  default        = "IU"
  latest         = true
}

Use fixed versions set by jetbrains_ide_versions

module "jetbrains_gateway" {
  count          = data.coder_workspace.me.start_count
  source         = "registry.coder.com/coder/jetbrains-gateway/coder"
  version        = "1.2.1"
  agent_id       = coder_agent.example.id
  folder         = "/home/coder/example"
  jetbrains_ides = ["IU", "PY"]
  default        = "IU"
  latest         = false
  jetbrains_ide_versions = {
    "IU" = {
      build_number = "243.21565.193"
      version      = "2024.3"
    }
    "PY" = {
      build_number = "243.21565.199"
      version      = "2024.3"
    }
  }
}

Use the latest EAP version

module "jetbrains_gateway" {
  count          = data.coder_workspace.me.start_count
  source         = "registry.coder.com/coder/jetbrains-gateway/coder"
  version        = "1.2.1"
  agent_id       = coder_agent.example.id
  folder         = "/home/coder/example"
  jetbrains_ides = ["GO", "WS"]
  default        = "GO"
  latest         = true
  channel        = "eap"
}

Due to the highest priority of the ide_download_link parameter in the (jetbrains-gateway://... within IDEA, the pre-configured download address will be overridden when using IDEA's offline mode. Therefore, it is necessary to configure the download_base_link parameter for the jetbrains_gateway module to change the value of ide_download_link.

module "jetbrains_gateway" {
  count              = data.coder_workspace.me.start_count
  source             = "registry.coder.com/coder/jetbrains-gateway/coder"
  version            = "1.2.1"
  agent_id           = coder_agent.example.id
  folder             = "/home/coder/example"
  jetbrains_ides     = ["GO", "WS"]
  releases_base_link = "https://releases.internal.site/"
  download_base_link = "https://download.internal.site/"
  default            = "GO"
}

Supported IDEs

This module and JetBrains Gateway support the following JetBrains IDEs: