Files
coder/docs/reference/faqs.md
T
coder[bot]andNick Vigilante a988af518c docs: rename the user-guides folder to workspaces (#31650)
> [!NOTE]
> Generated by Coder Agents. The branch and this description were
written by an AI agent and need human review.

## Summary

Fourth stacked PR for the docs IA overhaul. PR C renamed the User guides
sidebar section to **Workspaces**. This PR renames its folder to match,
so the folder tree and the sidebar agree (DOCS-1154). The section's
title, position, and contents don't change.

- `docs/user-guides/**` moves to `docs/workspaces/**` with `git mv`: 33
files. That includes pages that are not in the sidebar and the three
pages PR C moved in (`persistent-shared-workspaces.md`,
`cloning-git-repositories.md`, `speed-up-templates.md`).
- `docs/manifest/user-guides.yml` and `docs/manifest/user-guides/` (4
files) move to `docs/manifest/workspaces.yml` and
`docs/manifest/workspaces/`, and `index.yml` lists `workspaces.yml` in
the same position.
- Every relative link and image path is fixed, in moved pages and in
pages that link to them. This was done in one scripted pass from a clean
tree. `docs/images/` stays where it is, so images under
`docs/images/user-guides/` keep their names; only the relative paths
that point at them change.
- Commit 2, `chore: point in-product docs links at the new docs paths`,
updates docs URLs outside `docs/`, then regenerates the files built from
them with `make gen`. You can drop that commit; the redirects cover the
old URLs.
- Updated sources: `site/` `docs()` links and hardcoded docs URLs,
`cli/sharing.go` help text, `README.md`, `examples/templates/` READMEs
and `docker/main.tf`, templatebuilder base READMEs, and the doc-check
skill's audience persona.
- Regenerated files: the `coder sharing add/remove` CLI golden files,
`docs/reference/cli/sharing/{add,remove}.md`, and
`examples/examples.gen.json`.
- Commit 3, `fix: keep docs links healthy before the release`, keeps
links working on the live site until a release that includes this stack
becomes the default docs version:
- In hand-written pages, the docs commit's rewrite left 4 absolute
`https://coder.com/docs/workspaces/...` URLs. They are now relative
links, anchors kept: `admin/networking/wildcard-access-url.md`,
`install/operate/upgrade/esr-2.24-2.29-upgrade.md` (2 links), and
`workspaces/workspace-access/jetbrains/gateway.md`.
- Every hardcoded, unversioned `https://coder.com/docs/workspaces/...`
URL that commit 2 introduced outside `docs/` goes back to
`https://coder.com/docs/user-guides/...`. That covers 32 URLs in
`README.md`, `cli/sharing.go`, the examples and templatebuilder READMEs,
`examples/templates/docker/main.tf`, the `UserDropdownContent.tsx`
constant and its story assertion, and a JSDoc link in
`site/src/api/queries/workspaces.ts`. `make gen` then regenerated the
CLI golden files, `docs/reference/cli/sharing/{add,remove}.md`, and
`examples/examples.gen.json`. See "Post-release follow-up".
- The `site/` `docs()` changes stay, because those URLs are versioned
(`/docs/@vX.Y.Z/...`) and resolve once the release ships.

Stack: `docs/ia-ai-sections` (#31645, with Templates squash-merged in
#31646) → `docs/ia-tutorials-nav` (#31647) → **this PR**.

Refs: Linear DOCS-1154, DOCS-1179.

## Move map

| Old | New |
| --- | --- |
| `docs/user-guides/**` (33 files) | `docs/workspaces/**` |
| `docs/manifest/user-guides.yml` | `docs/manifest/workspaces.yml` |
| `docs/manifest/user-guides/**` (4 files) |
`docs/manifest/workspaces/**` |

## Redirects added

| Source | Destination |
| --- | --- |
| `/docs/user-guides` | `/docs/workspaces` |
| `/docs/user-guides/:path*` | `/docs/workspaces/:path*` |

Updated existing rules so none of them chain through the new wildcard:

| Source | Old destination | New destination |
| --- | --- | --- |
| `/docs/ai-coder/ide-agents` | `/docs/user-guides/workspace-access` |
`/docs/workspaces/workspace-access` |
| `/docs/tutorials/best-practices/speed-up-templates` |
`/docs/user-guides/speed-up-templates` |
`/docs/workspaces/speed-up-templates` |
| `/docs/tutorials/cloning-git-repositories` |
`/docs/user-guides/cloning-git-repositories` |
`/docs/workspaces/cloning-git-repositories` |
| `/docs/tutorials/persistent-shared-workspaces` |
`/docs/user-guides/persistent-shared-workspaces` |
`/docs/workspaces/persistent-shared-workspaces` |

**coder.com and router static redirects:** a chain simulation of
coder.com's and the router's static rules together with this branch's
`docs/redirects.json` finds one problem from this PR. The static
`/docs/workspaces` → `/docs/user-guides/workspace-management` rule in
both repos would hide the new `docs/workspaces/index.md` behind a
redirect to `/docs/workspaces/workspace-management`.
coder/coder.com#1201 and coder/docs-engine#304 remove it, together with
the Templates loops from #31645, once a release with this layout is the
docs mainline. If this PR ships in a later release than #31645, drop the
`/docs/workspaces` part of those PRs until then. The other static
`/docs/user-guides/...` destinations there still work; each now takes
two redirects.

## Deviations from the proposal

- **Not in Proposal 1.** The proposal only renamed the sidebar title.
This folder rename was requested afterward so the folder-driven renderer
shows the same name.
- **Generated files belong to commit 2.** Commit 1 doesn't edit
generated docs. They change only through their sources and `make gen`.
- **Left unchanged on purpose:**
  - `docs/images/user-guides/` keeps its name, as requested.
- `.github/workflows/test-docs-preview-mapper.sh` uses
`docs/user-guides/...` as synthetic fixture paths.
- `docs/templates/extending-templates/jetbrains-airgapped.md` has a
"file a GitHub issue" link whose URL-encoded body names
`coder.com/docs/user-guides/workspace-access/jetbrains/jetbrains-airgapped`.
That URL was already wrong before this PR (the page lives under
`templates/`), and it only pre-fills an issue body, so I left it.
- Database migrations and notification golden files: none of them
contain `user-guides` links.

## Open questions for Nick

1. Should `docs/images/user-guides/` be renamed to
`docs/images/workspaces/` in a follow-up, or stay as is?
2. Frontend review nits on existing code that this PR only touched; I
didn't change them:
- `UserDropdownContent.tsx` defines `CODER_DESKTOP_DOCS_URL` as a
hardcoded `https://coder.com/docs/...` URL instead of
`docs("/workspaces/desktop")`, which `SSHButton.tsx` uses for the same
page.
- The `UserDropdown` and `SecretsPageView` stories' `play` functions
only assert link attributes.

## Post-release follow-up

After a release that includes this stack becomes the default docs
version on coder.com, point these hardcoded URLs at the new paths. They
work today and redirect after the release. Anchors are unchanged. Rerun
`make gen` afterward to update the CLI golden files,
`docs/reference/cli/sharing/{add,remove}.md`, and
`examples/examples.gen.json`.

| Current (old) URL | Post-release URL | Files |
| --- | --- | --- |
| `https://coder.com/docs/user-guides/desktop` |
`https://coder.com/docs/workspaces/desktop` |
`site/src/modules/dashboard/Navbar/UserDropdown/UserDropdownContent.tsx`,
`UserDropdown.stories.tsx` |
| `https://coder.com/docs/user-guides/devcontainers` |
`https://coder.com/docs/workspaces/devcontainers` | `README.md` |
| `https://coder.com/docs/user-guides/shared-workspaces` |
`https://coder.com/docs/workspaces/shared-workspaces` | `cli/sharing.go`
(CLI help, 2 places) |
| `https://coder.com/docs/user-guides/workspace-access` |
`https://coder.com/docs/workspaces/workspace-access` | `README.md` |
|
`https://coder.com/docs/user-guides/workspace-access/jetbrains/toolbox`
| `https://coder.com/docs/workspaces/workspace-access/jetbrains/toolbox`
| `examples/templates/docker/main.tf` |
| `https://coder.com/docs/user-guides/workspace-dotfiles` |
`https://coder.com/docs/workspaces/workspace-dotfiles` |
`coderd/templatebuilder/bases/{azure-linux,docker,kubernetes}/README.md`,
`examples/templates/{azure-linux,docker,kubernetes}/README.md` |
| `https://coder.com/docs/user-guides/workspace-management` |
`https://coder.com/docs/workspaces/workspace-management` | `README.md`,
`coderd/templatebuilder/bases/{aws-linux,aws-windows,azure-linux,digitalocean-linux,docker,kubernetes}/README.md`,
`examples/templates/{aws-linux,aws-windows,azure-linux,azure-windows,digitalocean-linux,docker-devcontainer,docker-envbuilder,docker,kubernetes-devcontainer,kubernetes,nomad-docker}/README.md`,
`site/src/api/queries/workspaces.ts` (JSDoc) |

## Validation run

- `make gen/docs-manifest`: clean diff afterward.
- `make lint/docs-manifest`, `lint/docs-redirects` (`-base
docs/ia-tutorials-nav`: 36 rules OK), `lint/docs-html`, `lint/emdash`:
pass.
- `pnpm check-docs` (markdownlint + table formatter): pass.
- Vale over `docs/`: identical to `docs/ia-tutorials-nav` (12 warnings,
1 error, 645 suggestions, all pre-existing).
- Local relative-link check over `docs/**/*.md`: 0 unresolved (3410
links and images in 498 files).
- `grep -rn user-guides docs/` finds only `docs/redirects.json`, image
paths under `docs/images/user-guides/`, and the issue link above.
- Pre-commit hook: `make pre-commit-light` on the docs commit, and the
full `make pre-commit` (gen, fmt, lint/go, lint/ts, build, and others)
on the chore commit. `make gen` left a clean tree.
- Targeted tests:
- Go: `go test ./cli -run TestCommandHelp`, `./examples/...`,
`./coderd/templatebuilder/...`.
- Site: Vitest for the touched directories (22 files, 409 tests), and
the `UserDropdown` and `SecretsPageView` story tests (2 files, 59
tests).
- Every `docs()` path and `coder.com/docs` URL in the chore diff
resolves to a page and heading in this branch.
- Frontend deep review (all 8 roles) on the `site/` diff: no blocking or
should-fix findings; the nits are in question 2.
- Restacked on the rebased `docs/ia-tutorials-nav` (on `main` at
`ccf5ec74ae`). After the restack, `make gen/docs-manifest` (clean),
`lint/docs-manifest`, `lint/docs-redirects` (36 rules OK),
`lint/docs-html`, `lint/emdash`, `pnpm check-docs`, and the
relative-link and anchor check over the changed pages pass.
- Page counts: `docs/**/*.md` (excluding `.style`) 485 → 485;
`manifest.json` routes 482 → 482 (moves only).
- **Link health (commit 3):**
- linkspector 0.5.6 with `.github/.linkspector.yml` over all of `docs/`,
like the weekly docs job, run locally.
- `origin/main`: 0 errors. Before the fix (`7382a41faa`): 11 errors. 10
were `https://coder.com/docs/<new path>` 404s: the 6 from #31645 plus 4
`workspaces/...` URLs. The 11th was a transient Red Hat URL failure in
`install/server/openshift.md`, which is unchanged from `main` and passed
on reruns. After the fix (`c1f287fc1b`): 0 errors. Nothing is new
compared with `main`.
- After the fix: `make gen/docs-manifest` (clean), `lint/docs-manifest`,
`lint/docs-redirects` (36 rules OK against `docs/ia-tutorials-nav`),
`lint/docs-html`, `lint/emdash`, `pnpm check-docs`, and the
relative-link check (0 unresolved in 3419 links) pass. The full `make
pre-commit`, including `make gen`, passed on the commit.
- Outside `docs/`, no line in this stack adds an unversioned
`coder.com/docs` URL compared with `main`.
  - Tests after the fix:
- Go: `go test ./cli -run 'TestCommandHelp|TestServerYAMLConfig'`,
`./examples/...`, `./coderd/templatebuilder/...`, `./cli/cliui`.
- Site: Vitest for the touched directories (21 files, 404 tests), and
the `UserDropdown` story tests (28 tests).
- **Skipped:** the docs-engine sync check, which was not available in
this environment.

<details>
<summary>Implementation notes</summary>

- Same one-shot move script as PRs A to C, with a single rule,
`docs/user-guides/` → `docs/workspaces/`. It resolves each relative link
against the page's old directory, maps the target through the move,
recomputes it from the new directory, and also rewrites
`coder.com/docs/...` and
`github.com/coder/coder/(blob|edit|tree)/main/docs/...` URLs. It skips
fenced code blocks and inline code, and refuses to run on a dirty
`docs/` tree.
- After #31645 and #31647 got their link-health fixes, a plain rebase of
this branch conflicted in `esr-2.24-2.29-upgrade.md`, where both changed
the same table rows. Instead of resolving by hand, I rebuilt the docs
and chore commits from the fixed `docs/ia-tutorials-nav` with the same
scripts. The resulting docs commit differs from the earlier one only by
#31645's fix, and the chore commit touches the same 36 files.
- No hand edits were needed in the docs commit. The sidebar sources were
renamed with `git mv` and their `path`/`include` prefixes rewritten.
- The redirect script repointed every existing destination under
`/docs/user-guides` before appending the two new rules.
- Restacked on 2026-11-03 onto `docs/ia-tutorials-nav` at `76aed1a618`.
The chore commit conflicted with #31603 in
`site/src/pages/WorkspacesPage/WorkspaceHelpPopover.tsx`; both links
keep `main`'s `target="_blank" rel="noreferrer"` with only the path
changed, and the `WorkspacesPage` Vitest suite (24 tests) passes. Folded
into the docs commit: the `../user-guides/` links in
`docs/coder-agents/bring-your-own-mcp-servers.md`, a page `main` added,
now point at `../workspaces/`.

</details>

---------

Co-authored-by: coder[bot] <137810501+coder[bot]@users.noreply.github.com>
Co-authored-by: Nick Vigilante <nick.vigilante@coder.com>
2026-11-04 17:41:22 -05:00

22 KiB

title
title
FAQs

Frequently asked questions on Coder open source software (OSS) and licensed deployments. These frequently asked questions (FAQs) come from our community and customers, feel free to contribute to this page.

For other community resources, see our GitHub discussions, or join our Discord server.

How do I add a Premium trial license?

Visit https://coder.com/trial or contact sales@coder.com to get a trial key.

You can add a license through the UI or CLI

Coder UI

  1. With an Owner account, go to Admin settings > Deployment.

  2. Select Licenses from the sidebar, then Add a license:

    Add a license from the licenses screen

  3. On the Add a license screen, drag your .jwt file into Upload Your License or paste it into Paste Your License, then select Upload License:

    Add a license screen

Coder CLI

  1. Make sure you have the Coder CLI installed.

  2. Save your license key to disk and make note of the path.

  3. Open a terminal.

  4. Log in to your Coder deployment:

    coder login <access url>
    
  5. Run coder licenses add:

    • For a .jwt license file:

      coder licenses add -f <path to your license key>
      
    • For a text string:

      coder licenses add -l 1f5...765
      

Visit the licensing documentation for more information about licenses.

I'm experiencing networking issues, so want to disable Tailscale, STUN, Direct connections and force use of websocket

The primary developer use case is a local IDE connecting over SSH to a Coder workspace.

Coder's networking stack has intelligence to attempt a peer-to-peer or Direct connection between the local IDE and the workspace. However, this requires some additional protocols like User Datagram Protocol (UDP) and being able to reach a Session Traversal Utilities for Network Address Translation (STUN) server to echo the IP addresses of the local IDE machine and workspace, for sharing using a Wireguard Coordination Server. By default, Coder assumes Internet and attempts to reach Google's STUN servers to perform this IP echo.

Operators experimenting with Coder may run into networking issues if UDP (which STUN requires) or the STUN servers are unavailable, potentially resulting in lengthy local IDE and SSH connection times as the Coder control plane attempts to establish these direct connections.

Setting the following flags as shown disables this logic to simplify troubleshooting.

Flag Value Meaning
CODER_BLOCK_DIRECT true Blocks direct connections
CODER_DERP_SERVER_STUN_ADDRESSES "disable" Disables STUN
CODER_DERP_FORCE_WEBSOCKETS true Forces websockets over Tailscale Designated Encrypted Relay for Packets (DERP)

How do I configure NGINX as the reverse proxy in front of Coder?

This tutorial in our docs explains in detail how to configure NGINX with Coder so that our Tailscale Wireguard networking functions properly.

How do I hide some of the default icons in a workspace like VS Code Desktop, Terminal, SSH, Ports?

The visibility of Coder apps is configurable in the template. To change the default (shows all), add this block inside the coder_agent of a template and configure as needed:

  display_apps {
    vscode = false
    vscode_insiders = false
    ssh_helper = false
    port_forwarding_helper = false
    web_terminal = true
  }

This example will hide all built-in coder_app icons except the web terminal.

I want to allow code-server to be accessible by other users in my deployment

We don't recommend that you share a web IDE, but if you need to, the following deployment environment variable settings are required.

Set deployment (Kubernetes) to allow path app sharing:

# allow authenticated users to access path-based workspace apps
- name: CODER_DANGEROUS_ALLOW_PATH_APP_SHARING
  value: "true"
# allow Coder owner roles to access path-based workspace apps
- name: CODER_DANGEROUS_ALLOW_PATH_APP_SITE_OWNER_ACCESS
  value: "true"

In the template, set coder_app share option to authenticated and when a workspace is built with this template, the pretty globe shows up next to path-based code-server:

resource "coder_app" "code-server" {
  ...
  share        = "authenticated"
  ...
}

I installed Coder and created a workspace but the icons do not load

An important concept to understand is that Coder creates workspaces which have an agent that must be able to reach the control plane.

If the CODER_ACCESS_URL is not accessible from a workspace, the workspace may build, but the agent cannot reach Coder, and thus the missing icons. For example, Terminal, IDEs, Apps.

By default, coder server automatically creates an Internet-accessible reverse proxy so that workspaces you create can reach the control plane.

If you are doing a standalone install, for example, on a MacBook and want to build workspaces in Docker Desktop, everything is self-contained and workspaces (containers in Docker Desktop) can reach the control plane.

coder server --access-url http://localhost:3000 --address 0.0.0.0:3000

Even coder server which creates a reverse proxy, will let you use http://localhost to access Coder from a browser.

I updated a template, and an existing workspace based on that template fails to start

When updating a template, be aware of potential issues with input variables. For example, if a template prompts users to choose options like a code-server VS Code IDE release, a container image, or a VS Code extension, removing any of these values can lead to existing workspaces failing to start. This issue occurs because the Terraform state will not be in sync with the new template.

However, a lesser-known CLI sub-command, coder update, can resolve this issue. This command re-prompts users to re-enter the input variables, potentially saving the workspace from a failed status.

coder update --always-prompt <workspace name>

I'm running coder on a VM with systemd but latest release installed isn't showing up

Take, for example, a Coder deployment on a VM with a 2 shared vCPU systemd service. In this scenario, it's necessary to reload the daemon and then restart the Coder service. This prevents the systemd daemon from trying to reference the previous Coder release service since the unit file has changed.

The following commands can be used to update Coder and refresh the service:

curl -fsSL https://coder.com/install.sh | sh
sudo systemctl daemon-reload
sudo systemctl restart coder.service

I'm using the built-in Postgres database and forgot admin email I set up

  1. Run the coder server command below to retrieve the psql connection URL which includes the database user and password.
  2. psql into Postgres, and do a select query on the users table.
  3. Restart the control plane, pull up the Coder UI and log in (you will still need your password)
coder server postgres-builtin-url
psql "postgres://coder@localhost:53737/coder?sslmode=disable&password=I2S...pTk"

How to find out Coder's latest Terraform provider version?

Coder is on the HashiCorp's Terraform registry. Check this frequently to make sure you are on the latest version.

Sometimes, the version may change and resource configurations will either become deprecated or new ones will be added when you get warnings or errors creating and pushing templates.

How can I set up TLS for my deployment and not create a signed certificate?

Caddy is an easy-to-configure reverse proxy that also automatically creates certificates from Let's Encrypt. Install docs here You can start Caddy as a systemd service.

The Caddyfile configuration will appear like this where 127.0.0.1:3000 is your CODER_ACCESS_URL:

coder.example.com {

  reverse_proxy 127.0.0.1:3000

  tls {

    issuer acme {
      email user@example.com
    }

  }
}

I'm using Caddy as my reverse proxy in front of Coder. How do I set up a wildcard domain for port forwarding?

Caddy requires your DNS provider's credentials to create wildcard certificates. This involves building the Caddy binary from source with the DNS provider plugin added. For example, Google Cloud DNS provider here

To compile Caddy, the host running Coder requires Go. Once installed, replace the existing Caddy binary in usr/bin and restart the Caddy service.

The updated Caddyfile configuration will look like this:

*.coder.example.com, coder.example.com {

  reverse_proxy 127.0.0.1:3000

  tls {
    issuer acme {
      email user@example.com
      dns googleclouddns {
        gcp_project my-gcp-project
      }
    }
  }

}

Can I use local or remote Terraform Modules in Coder templates?

One way is to reference a Terraform module from a GitHub repo to avoid duplication and then just extend it or pass template-specific parameters/resources:

# template1/main.tf
module "central-coder-module" {
  source = "github.com/org/central-coder-module"
  myparam = "custom-for-template1"
}

resource "ebs_volume" "custom_template1_only_resource" {
}
# template2/main.tf
module "central-coder-module" {
  source = "github.com/org/central-coder-module"
  myparam = "custom-for-template2"
  myparam2 = "bar"
}

resource "aws_instance" "custom_template2_only_resource" {
}

Another way using local modules is to symlink the module directory inside the template directory and then tar the template.

ln -s modules template_1/modules
tar -cvh -C ./template_1 | coder templates <push|create> -d - <name>

References:

Can I run Coder in an air-gapped or offline mode? (no Internet)?

Yes, Coder can be deployed in air-gapped or offline mode.

Our product bundles with the Terraform binary so assume access to terraform.io during installation. The docs outline rebuilding the Coder container with Terraform built-in as well as any required Terraform providers.

Direct networking from local SSH to a Coder workspace needs a STUN server. Coder defaults to Google's STUN servers, so you can either create your STUN server in your network or disable and force all traffic through the control plane's DERP proxy.

Create a randomized computer_name for an Azure VM

Azure VMs have a 15 character limit for the computer_name which can lead to duplicate name errors.

This code produces a hashed value that will be difficult to replicate.

locals {
  concatenated_string = "${data.coder_workspace.me.name}+${data.coder_workspace_owner.me.name}"
  hashed_string = md5(local.concatenated_string)
  truncated_hash = substr(local.hashed_string, 0, 16)
}

Do you have example JetBrains Gateway templates?

In August 2023, JetBrains certified the Coder plugin signifying enhanced stability and reliability.

The Coder plugin will appear in the Gateway UI when opened.

Selecting the most suitable template depends on how the deployment manages JetBrains IDE versions. If downloading from jetbrains.com is acceptable, see the example templates below which specifies the product code, IDE version and build number in the coder_app resource. This will present an icon in the workspace dashboard which, when selected, will look for a locally installed Gateway, and open it. Alternatively, the IDE can be baked into the container image and manually open Gateway (or IntelliJ which has Gateway built-in), using a session token to Coder and then open the IDE.

What options do I have for adding VS Code extensions into code-server, VS Code Desktop or Microsoft's Code Server?

Coder has an open-source project called code-marketplace which is a private VS Code extension marketplace. There is even integration with JFrog Artifactory.

You can also use Microsoft's code-server - which is like Coder's, but it can connect to Microsoft's extension marketplace so Copilot and chat can be retrieved there.

Another option is to use VS Code Desktop (local) and that connects to Microsoft's marketplace.

I want to run Docker for my workspaces but not install Docker Desktop

Colima is a Docker Desktop alternative.

This example is meant for a users who want to try out Coder on a macOS device.

Install Colima and docker with:

brew install colima
brew install docker

Start Colima:

colima start

Start Colima with specific compute options:

colima start --cpu 4 --memory 8

Starting Colima on a M3 MacBook Pro:

colima start --arch x86_64  --cpu 4 --memory 8 --disk 10

Colima will show the path to the docker socket so we have a community template that prompts the Coder admin to enter the Docker socket as a Terraform variable.

How to make a coder_app optional?

An example use case is the user should decide if they want a browser-based IDE like code-server when creating the workspace.

  1. Add a coder_parameter with type bool to ask the user if they want the code-server IDE

    data "coder_parameter" "code_server" {
        name        = "Do you want code-server in your workspace?"
        description = "Use VS Code in a browser."
        type        = "bool"
        default     = false
        mutable     = true
        icon        = "/icon/code.svg"
        order       = 6
    }
    
  2. Add conditional logic to the startup_script to install and start code-server depending on the value of the added coder_parameter

    # install and start code-server, VS Code in a browser
    
    if [ ${data.coder_parameter.code_server.value} = true ]; then
    echo "🧑🏼‍💻 Downloading and installing the latest code-server IDE..."
    curl -fsSL https://code-server.dev/install.sh | sh
    code-server --auth none --port 13337 >/dev/null 2>&1 &
    fi
    
  3. Add a Terraform meta-argument count in the coder_app resource.

    This creates the resource only if the coder_parameter is true.

    # code-server
    resource "coder_app" "code-server" {
    count         = data.coder_parameter.code_server.value ? 1 : 0
    agent_id      = coder_agent.coder.id
    slug          = "code-server"
    display_name  = "code-server"
    icon          = "/icon/code.svg"
    url           = "http://localhost:13337?folder=/home/coder"
    subdomain = false
    share     = "owner"
    
    healthcheck {
        url       = "http://localhost:13337/healthz"
        interval  = 3
        threshold = 10
    }
    }
    

Why am I getting this "remote host doesn't meet VS Code Server's prerequisites" error when opening up VSCode remote in a Linux environment?

VS Code Server prerequisite

It is because, more than likely, the supported OS of either the container image or VM/virtual private server (VPS) doesn't have the proper C libraries to run the VS Code Server. For instance, Alpine is not supported at all. If so, you need to find a container image or supported OS for the VS Code Server. For more information on OS prerequisites for Linux, look at the VSCode docs. https://code.visualstudio.com/docs/remote/linux#_local-linux-prerequisites

How can I resolve disconnects when connected to Coder via JetBrains Gateway?

If your JetBrains IDE is disconnected for a long period of time due to a network change (for example turning off a virtual private network (VPN)), you may find that the IDE will not reconnect once the network is re-established (for example turning a VPN back on). When this happens a persistent message will appear similar to the below:

No internet connection. Changes in the document might be lost. Trying to reconnect…

To resolve this, add this entry to your SSH config file on your local machine:

Host coder-jetbrains--*
  ServerAliveInterval 5

This will make SSH check that it can contact the server every five seconds. If it fails to do so ServerAliveCountMax times (3 by default for a total of 15 seconds) then it will close the connection which forces JetBrains to recreate the hung session. You can tweak ServerAliveInterval and ServerAliveCountMax to increase or decrease the total timeout.

Note that the JetBrains Gateway configuration blocks for each host in your SSH config file will be overwritten by the JetBrains Gateway client when it re-authenticates to your Coder deployment so you must add the above config as a separate block and not add it to any existing ones.

How can I restrict inbound/outbound file transfers from Coder workspaces?

In certain environments, it is essential to keep confidential files within workspaces and prevent users from uploading or downloading resources using tools like scp or rsync.

To achieve this, template admins can use the environment variable CODER_AGENT_BLOCK_FILE_TRANSFER to enable additional SSH command controls. This variable allows the system to check if the executed application is on the block list, which includes nc, rsync, scp, and sftp.

resource "docker_container" "workspace" {
  ...
  env = [
    "CODER_AGENT_TOKEN=${coder_agent.main.token}",
    "CODER_AGENT_BLOCK_FILE_TRANSFER=true",
    ...
  ]
}

Important Notice

This control operates at the ssh-exec level or during sftp sessions. While it can help prevent automated file transfers using the specified tools, users can still SSH into the workspace and manually initiate file transfers. The primary purpose of this feature is to warn and discourage users from downloading confidential resources to their local machines.

Agent API capabilities, such as file operations performed by AI agents in Coder Agents chat (including chat file uploads into the workspace), are not affected by this setting because they do not go through the SSH transfer path.

The sftp subsystem is blocked in full, not just the sftp command, so any workflow that moves files over SSH File Transfer Protocol (SFTP) stops working. This includes IDE remote file browsers that rely on it.

Coder Desktop file sync also stops working, though for a different reason. File sync runs Mutagen over SSH, and Mutagen installs its remote agent binary with scp, which is on the block list.

Confirm which workflows your developers depend on before you enable this setting.

For more advanced security needs, consider adopting an endpoint security solution.

How do I change the access URL for my control plane?

You may want to change the default domain that's used to access coder, that is, yourcompany.coder.com and find yourself unfamiliar with the process.

To change the access URL associated with your control plane, you can edit any of the following variables:

  • CLI using the --access-url flag
  • YAML using the accessURL option
  • or the CODER_ACCESS_URL environment variable.

For example, if you're using an environment file to configure your control plane, you'll want to edit the file located at /etc/coder.d/coder.env and edit the following:

CODER_ACCESS_URL=https://yourcompany.coder.com to your new desired URL.

Then save your changes, and reload daemon-ctl using the following command:

systemctl daemon-reload

and restart the service using:

systemctl restart coder

After coder restarts, your changes should be applied and should reflect in the admin settings.