docs: update port forwarding docs to include Coder Desktop (#18870)

Noticed that Coder Desktop was missing from port-forwarding docs which
is kind of a big feature for Coder Connect.


[preview](https://coder.com/docs/@atif%2Fdesktop-ports/user-guides/workspace-access/port-forwarding)

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
Co-authored-by: Edward Angert <EdwardAngert@users.noreply.github.com>
This commit is contained in:
Atif Ali
2025-07-16 19:57:55 +00:00
committed by GitHub
co-authored by EdwardAngert Edward Angert
parent b4c9725443
commit ca6b5e3415
@@ -6,17 +6,19 @@ Port forwarding lets developers securely access processes on their Coder
workspace from a local machine. A common use case is testing web applications in
a browser.
There are three ways to forward ports in Coder:
There are multiple ways to forward ports in Coder:
- The `coder port-forward` command
- Dashboard
- SSH
| Method | Details |
|:----------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Coder Desktop](#coder-desktop) | Uses a VPN tunnel to your workspaces and provides access to all running ports. Supports peer-to-peer connections for the best performance. |
| [`coder port-forward` command](#the-coder-port-forward-command) | Can be used to forward specific TCP or UDP ports from the remote workspace so they can be accessed locally. Supports peer-to-peer connections for the best performance. |
| [Dashboard](#dashboard) | Proxies traffic through the Coder control plane. |
| [SSH](#ssh) | Forwards ports over an SSH connection. |
The `coder port-forward` command is generally more performant than:
## Coder Desktop
1. The Dashboard which proxies traffic through the Coder control plane versus
peer-to-peer which is possible with the Coder CLI
1. `sshd` which does double encryption of traffic with both Wireguard and SSH
[Coder Desktop](../desktop/index.md) provides seamless access to your remote workspaces, eliminating the need to install a CLI or manually configure port forwarding.
Access all your ports at `<workspace-name>.coder:PORT`.
## The `coder port-forward` command
@@ -62,7 +64,7 @@ where each segment of hostnames must not exceed 63 characters. If your app
name, agent name, workspace name and username exceed 63 characters in the
hostname, port forwarding via the dashboard will not work.
### From an coder_app resource
### From a coder_app resource
One way to port forward is to configure a `coder_app` resource in the
workspace's template. This approach shows a visual application icon in the