docs: reorganize JetBrains docs (#17995)

This pull request introduces significant updates to documentation and
references related to JetBrains IDEs, including rebranding,
restructuring, and adding new guides.

[Preview](https://coder.com/docs/@atif%2Fjetbrains-reorganization)

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
This commit is contained in:
Atif Ali
2025-05-29 17:56:44 -07:00
committed by GitHub
parent bedeb4710b
commit 25e2146200
12 changed files with 287 additions and 416 deletions

View File

@ -0,0 +1,164 @@
# JetBrains IDEs in an air-gapped environment
In networks that restrict access to the internet, you will need to leverage the
JetBrains Client Installer to download and save the IDE clients locally. Please
see the
[JetBrains documentation for more information](https://www.jetbrains.com/help/idea/fully-offline-mode.html).
This page is an example that the Coder team used as a proof-of-concept (POC) of the JetBrains Gateway Offline Mode solution.
We used Ubuntu on a virtual machine to test the steps.
If you have a suggestion or encounter an issue, please
[file a GitHub issue](https://github.com/coder/coder/issues/new?title=request%28docs%29%3A+jetbrains-airgapped+-+request+title+here%0D%0A&labels=["community","docs"]&body=doc%3A+%5Bjetbrains-airgapped%5D%28https%3A%2F%2Fcoder.com%2Fdocs%2Fuser-guides%2Fworkspace-access%2Fjetbrains%2Fjetbrains-airgapped%29%0D%0A%0D%0Aplease+enter+your+request+here%0D%0A).
## 1. Deploy the server and install the Client Downloader
Install the JetBrains Client Downloader binary. Note that the server must be a Linux-based distribution:
```shell
wget https://download.jetbrains.com/idea/code-with-me/backend/jetbrains-clients-downloader-linux-x86_64-1867.tar.gz && \
tar -xzvf jetbrains-clients-downloader-linux-x86_64-1867.tar.gz
```
## 2. Install backends and clients
JetBrains Gateway requires both a backend to be installed on the remote host
(your Coder workspace) and a client to be installed on your local machine. You
can host both on the server in this example.
See here for the full
[JetBrains product list and builds](https://data.services.jetbrains.com/products).
Below is the full list of supported `--platforms-filter` values:
```console
windows-x64, windows-aarch64, linux-x64, linux-aarch64, osx-x64, osx-aarch64
```
To install both backends and clients, you will need to run two commands.
### Backends
```shell
mkdir ~/backends
./jetbrains-clients-downloader-linux-x86_64-1867/bin/jetbrains-clients-downloader --products-filter <product-code> --build-filter <build-number> --platforms-filter linux-x64,windows-x64,osx-x64 --download-backends ~/backends
```
### Clients
This is the same command as above, with the `--download-backends` flag removed.
```shell
mkdir ~/clients
./jetbrains-clients-downloader-linux-x86_64-1867/bin/jetbrains-clients-downloader --products-filter <product-code> --build-filter <build-number> --platforms-filter linux-x64,windows-x64,osx-x64 ~/clients
```
We now have both clients and backends installed.
## 3. Install a web server
You will need to run a web server in order to serve requests to the backend and
client files. We installed `nginx` and setup an FQDN and routed all requests to
`/`. See below:
```console
server {
listen 80 default_server;
listen [::]:80 default_server;
root /var/www/html;
index index.html index.htm index.nginx-debian.html;
server_name _;
location / {
root /home/ubuntu;
}
}
```
Then, configure your DNS entry to point to the IP address of the server. For the
purposes of the POC, we did not configure TLS, although that is a supported
option.
## 4. Add Client Files
You will need to add the following files on your local machine in order for
Gateway to pull the backend and client from the server.
```shell
$ cat productsInfoUrl # a path to products.json that was generated by the backend's downloader (it could be http://, https://, or file://)
https://internal.site/backends/<PRODUCT_CODE>/products.json
$ cat clientDownloadUrl # a path for clients that you got from the clients' downloader (it could be http://, https://, or file://)
https://internal.site/clients/
$ cat jreDownloadUrl # a path for JBR that you got from the clients' downloader (it could be http://, https://, or file://)
https://internal.site/jre/
$ cat pgpPublicKeyUrl # a URL to the KEYS file that was downloaded with the clients builds.
https://internal.site/KEYS
```
The location of these files will depend upon your local operating system:
<div class="tabs">
### macOS
```console
# User-specific settings
/Users/UserName/Library/Application Support/JetBrains/RemoteDev
# System-wide settings
/Library/Application Support/JetBrains/RemoteDev/
```
### Linux
```console
# User-specific settings
$HOME/.config/JetBrains/RemoteDev
# System-wide settings
/etc/xdg/JetBrains/RemoteDev/
```
### Windows
```console
# User-specific settings
HKEY_CURRENT_USER registry
# System-wide settings
HKEY_LOCAL_MACHINE registry
```
Additionally, create a string for each setting with its appropriate value in
`SOFTWARE\JetBrains\RemoteDev`:
![JetBrains offline - Windows](../../../images/gateway/jetbrains-offline-windows.png)
</div>
## 5. Setup SSH connection with JetBrains Gateway
With the server now configured, you can now configure your local machine to use
Gateway. Here is the documentation to
[setup SSH config via the Coder CLI](../../../user-guides/workspace-access/index.md#configure-ssh).
On the Gateway side, follow our guide here until step 16.
Instead of downloading from jetbrains.com, we will point Gateway to our server
endpoint. Select `Installation options...` and select `Use download link`. Note
that the URL must explicitly reference the archive file:
![Offline Gateway](../../../images/gateway/offline-gateway.png)
Click `Download IDE and Connect`. Gateway should now download the backend and
clients from the server into your remote workspace and local machine,
respectively.
## Next steps
- [Pre-install the JetBrains IDEs backend in your workspace](./jetbrains-preinstall.md)

View File

@ -1,119 +0,0 @@
# Pre-install JetBrains Gateway in a template
For a faster JetBrains Gateway experience, pre-install the IDEs backend in your template.
> [!NOTE]
> This guide only talks about installing the IDEs backend. For a complete guide on setting up JetBrains Gateway with client IDEs, refer to the [JetBrains Gateway air-gapped guide](../../../user-guides/workspace-access/jetbrains/jetbrains-airgapped.md).
## Install the Client Downloader
Install the JetBrains Client Downloader binary:
```shell
wget https://download.jetbrains.com/idea/code-with-me/backend/jetbrains-clients-downloader-linux-x86_64-1867.tar.gz && \
tar -xzvf jetbrains-clients-downloader-linux-x86_64-1867.tar.gz
rm jetbrains-clients-downloader-linux-x86_64-1867.tar.gz
```
## Install Gateway backend
```shell
mkdir ~/JetBrains
./jetbrains-clients-downloader-linux-x86_64-1867/bin/jetbrains-clients-downloader --products-filter <product-code> --build-filter <build-number> --platforms-filter linux-x64 --download-backends ~/JetBrains
```
For example, to install the build `243.26053.27` of IntelliJ IDEA:
```shell
./jetbrains-clients-downloader-linux-x86_64-1867/bin/jetbrains-clients-downloader --products-filter IU --build-filter 243.26053.27 --platforms-filter linux-x64 --download-backends ~/JetBrains
tar -xzvf ~/JetBrains/backends/IU/*.tar.gz -C ~/JetBrains/backends/IU
rm -rf ~/JetBrains/backends/IU/*.tar.gz
```
## Register the Gateway backend
Add the following command to your template's `startup_script`:
```shell
~/JetBrains/backends/IU/ideaIU-243.26053.27/bin/remote-dev-server.sh registerBackendLocationForGateway
```
## Configure JetBrains Gateway Module
If you are using our [jetbrains-gateway](https://registry.coder.com/modules/jetbrains-gateway) module, you can configure it by adding the following snippet to your template:
```tf
module "jetbrains_gateway" {
count = data.coder_workspace.me.start_count
source = "registry.coder.com/modules/jetbrains-gateway/coder"
version = "1.0.28"
agent_id = coder_agent.main.id
folder = "/home/coder/example"
jetbrains_ides = ["IU"]
default = "IU"
latest = false
jetbrains_ide_versions = {
"IU" = {
build_number = "243.26053.27"
version = "2024.3"
}
}
}
resource "coder_agent" "main" {
...
startup_script = <<-EOF
~/JetBrains/backends/IU/ideaIU-243.26053.27/bin/remote-dev-server.sh registerBackendLocationForGateway
EOF
}
```
## Dockerfile example
If you are using Docker based workspaces, you can add the command to your Dockerfile:
```dockerfile
FROM ubuntu
# Combine all apt operations in a single RUN command
# Install only necessary packages
# Clean up apt cache in the same layer
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
curl \
git \
golang \
sudo \
vim \
wget \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
# Create user in a single layer
ARG USER=coder
RUN useradd --groups sudo --no-create-home --shell /bin/bash ${USER} \
&& echo "${USER} ALL=(ALL) NOPASSWD:ALL" >/etc/sudoers.d/${USER} \
&& chmod 0440 /etc/sudoers.d/${USER}
USER ${USER}
WORKDIR /home/${USER}
# Install JetBrains Gateway in a single RUN command to reduce layers
# Download, extract, use, and clean up in the same layer
RUN mkdir -p ~/JetBrains \
&& wget -q https://download.jetbrains.com/idea/code-with-me/backend/jetbrains-clients-downloader-linux-x86_64-1867.tar.gz -P /tmp \
&& tar -xzf /tmp/jetbrains-clients-downloader-linux-x86_64-1867.tar.gz -C /tmp \
&& /tmp/jetbrains-clients-downloader-linux-x86_64-1867/bin/jetbrains-clients-downloader \
--products-filter IU \
--build-filter 243.26053.27 \
--platforms-filter linux-x64 \
--download-backends ~/JetBrains \
&& tar -xzf ~/JetBrains/backends/IU/*.tar.gz -C ~/JetBrains/backends/IU \
&& rm -f ~/JetBrains/backends/IU/*.tar.gz \
&& rm -rf /tmp/jetbrains-clients-downloader-linux-x86_64-1867* \
&& rm -rf /tmp/*.tar.gz
```
## Next steps
- [Pre-install the Client IDEs](../../../user-guides/workspace-access/jetbrains/jetbrains-airgapped.md#1-deploy-the-server-and-install-the-client-downloader)

View File

@ -0,0 +1,95 @@
# Pre-install JetBrains IDEs in your template
For a faster first time connection with JetBrains IDEs, pre-install the IDEs backend in your template.
> [!NOTE]
> This guide only talks about installing the IDEs backend. For a complete guide on setting up JetBrains Gateway with client IDEs, refer to the [JetBrains Gateway air-gapped guide](./jetbrains-airgapped.md).
## Install the Client Downloader
Install the JetBrains Client Downloader binary:
```shell
wget https://download.jetbrains.com/idea/code-with-me/backend/jetbrains-clients-downloader-linux-x86_64-1867.tar.gz && \
tar -xzvf jetbrains-clients-downloader-linux-x86_64-1867.tar.gz
rm jetbrains-clients-downloader-linux-x86_64-1867.tar.gz
```
## Install Gateway backend
```shell
mkdir ~/JetBrains
./jetbrains-clients-downloader-linux-x86_64-1867/bin/jetbrains-clients-downloader --products-filter <product-code> --build-filter <build-number> --platforms-filter linux-x64 --download-backends ~/JetBrains
```
For example, to install the build `243.26053.27` of IntelliJ IDEA:
```shell
./jetbrains-clients-downloader-linux-x86_64-1867/bin/jetbrains-clients-downloader --products-filter IU --build-filter 243.26053.27 --platforms-filter linux-x64 --download-backends ~/JetBrains
tar -xzvf ~/JetBrains/backends/IU/*.tar.gz -C ~/JetBrains/backends/IU
rm -rf ~/JetBrains/backends/IU/*.tar.gz
```
## Register the Gateway backend
Add the following command to your template's `startup_script`:
```shell
~/JetBrains/*/bin/remote-dev-server.sh registerBackendLocationForGateway
```
## Configure JetBrains Gateway Module
If you are using our [jetbrains-gateway](https://registry.coder.com/modules/coder/jetbrains-gateway) module, you can configure it by adding the following snippet to your template:
```tf
module "jetbrains_gateway" {
count = data.coder_workspace.me.start_count
source = "registry.coder.com/modules/jetbrains-gateway/coder"
version = "1.0.29"
agent_id = coder_agent.main.id
folder = "/home/coder/example"
jetbrains_ides = ["IU"]
default = "IU"
latest = false
jetbrains_ide_versions = {
"IU" = {
build_number = "251.25410.129"
version = "2025.1"
}
}
}
resource "coder_agent" "main" {
...
startup_script = <<-EOF
~/JetBrains/*/bin/remote-dev-server.sh registerBackendLocationForGateway
EOF
}
```
## Dockerfile example
If you are using Docker based workspaces, you can add the command to your Dockerfile:
```dockerfile
FROM codercom/enterprise-base:ubuntu
# JetBrains IDE installation (configurable)
ARG IDE_CODE=IU
ARG IDE_VERSION=2025.1
# Fetch and install IDE dynamically
RUN mkdir -p ~/JetBrains \
&& IDE_URL=$(curl -s "https://data.services.jetbrains.com/products/releases?code=${IDE_CODE}&majorVersion=${IDE_VERSION}&latest=true" | jq -r ".${IDE_CODE}[0].downloads.linux.link") \
&& IDE_NAME=$(curl -s "https://data.services.jetbrains.com/products/releases?code=${IDE_CODE}&majorVersion=${IDE_VERSION}&latest=true" | jq -r ".${IDE_CODE}[0].name") \
&& echo "Installing ${IDE_NAME}..." \
&& wget -q ${IDE_URL} -P /tmp \
&& tar -xzf /tmp/$(basename ${IDE_URL}) -C ~/JetBrains \
&& rm -f /tmp/$(basename ${IDE_URL}) \
&& echo "${IDE_NAME} installed successfully"
```
## Next steps
- [Pre-install the Client IDEs](./jetbrains-airgapped.md#1-deploy-the-server-and-install-the-client-downloader)