[code-server](https://github.com/coder/coder) is our supported method of running VS Code in the web browser. A simple way to install code-server in Linux/macOS workspaces is via the Coder agent in your template:
curl -fsSL https://code-server.dev/install.sh | sh
code-server --auth none --port 13337
EOF
}
```
For advanced use, we recommend installing code-server in your VM snapshot or container image. Here's a Dockerfile which leverages some special [code-server features](https://coder.com/docs/code-server/):
```Dockerfile
FROM codercom/enterprise-base:ubuntu
# install a specific code-server version
RUN curl -fsSL https://code-server.dev/install.sh | sh -s -- --version=4.3.0
[JetBrains Projector](https://jetbrains.github.io/projector-client/mkdocs/latest/) is a JetBrains Incubator project which renders JetBrains IDEs in the web browser.
> It is common to see latency and performance issues with Projector. We recommend using [JetBrains Gateway](https://youtrack.jetbrains.com/issues/GTW) whenever possible (also no Template edits required!)
For advanced users who want to make a custom image, you can install the Projector CLI in the `startup_script` of the `coder_agent` resource in a Coder template. Using the Projector CLI, you can use `projector ide autoinstall` and `projector run` to download and start a JetBrains IDE in your workspace.
![IntelliJ in Coder](../images/projector-intellij.png)
In this example, the version of JetBrains IntelliJ IDE is passed in from a Terraform input variable. You create a JetBrains icon in the workspace using a `coder_app` resource.
> There is a known issue passing query string parameters when opening a JetBrains IDE from an icon in your workspace ([#2669](https://github.com/coder/coder/issues/2669)). Note the `grep` statement to remove an optional password token from the configuration so a query string parameter is not passed.
```hcl
variable "jetbrains-ide" {
description = "JetBrains IntelliJ IDE"
default = "IntelliJ IDEA Community Edition 2022.1.3"
validation {
condition = contains([
"IntelliJ IDEA Community Edition 2022.1.3",
"IntelliJ IDEA Community Edition 2021.3",
"IntelliJ IDEA Ultimate 2022.1.3",
"IntelliJ IDEA Ultimate 2021.3"
], var.jetbrains-ide)
# Find all compatible IDEs with the `projector IDE find` command
error_message = "Invalid JetBrains IDE!"
}
}
resource "coder_agent" "coder" {
dir = "/home/coder"
startup_script = <<EOT
#!/bin/bash
# install projector
PROJECTOR_BINARY=/home/coder/.local/bin/projector
if [ -f $PROJECTOR_BINARY ]; then
echo 'projector has already been installed - check for update'
/home/coder/.local/bin/projector self-update 2>&1 | tee projector.log
else
echo 'installing projector'
pip3 install projector-installer --user 2>&1 | tee projector.log
fi
echo 'access projector license terms'
/home/coder/.local/bin/projector --accept-license 2>&1 | tee -a projector.log
![PyCharm in Coder](../images/projector-pycharm.png)
> Coder OSS currently does not perform a health check([#2662](https://github.com/coder/coder/issues/2662)) that any IDE or commands in the `startup_script` have completed, so wait a minute or so before opening the JetBrains or code-server icons. As a precaution, you can open Terminal and run `htop` to see if the processes have completed.
Check out this [RStudio Dockerfile](https://github.com/mark-theshark/dockerfiles/blob/main/rstudio/no-args/Dockerfile) for a starting point to creating a template.
![RStudio in Coder](../images/rstudio-port-forward.png)