This repository was archived by the owner on Aug 18, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 80
feat: document proxy settings #830
Merged
+129
−2
Merged
Changes from 2 commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
56cd373
feat: document proxy settings
6536e36
update inks
31989a3
edit text
bdca0a4
lint
6572448
update manifest
514da2e
apply Cian's suggestions
c92639e
Merge remote-tracking branch 'origin/main' into jawnsy/sc-20177/docum…
c6f659b
minor edits
de54b02
minor edits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,97 @@ | ||
| --- | ||
| title: Proxies | ||
| description: Learn how to configure forward and reverse proxies for Coder. | ||
| --- | ||
|
|
||
| If your Coder installation will access the Internet through a forward proxy, see | ||
| the reference for configuring [Forward proxies](#forward-proxies). | ||
|
|
||
| If you have a reverse proxy in front of Coder, such as an Ingress Controller | ||
| internal to the cluster, then see the reference for configuring | ||
| [Reverse proxies](#reverse-proxies). | ||
|
|
||
| ## Forward proxies | ||
|
|
||
| Coder supports proxies for outbound HTTP and HTTPS connections by configuring | ||
| the `coderd.proxy.http` and `coderd.proxy.https` settings in the Helm chart, | ||
| which correspond to the standard `http_proxy` and `https_proxy` environment | ||
| variables, respectively. | ||
|
|
||
| If the proxy URL does not include a scheme, Coder will default to treating it as | ||
| an HTTP proxy. It is also possible to connect to the proxy using HTTPS or SOCKS5 | ||
khorne3 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| protocols. | ||
|
|
||
| For an HTTP proxy with address `http://localhost:3128`, use the setting: | ||
|
|
||
| ```yaml | ||
| coderd: | ||
| proxy: | ||
| http: localhost:3128 | ||
| ``` | ||
| For an HTTPS proxy with address `https://localhost:3128`, include the scheme: | ||
|
|
||
| ```yaml | ||
| coderd: | ||
| proxy: | ||
| http: https://localhost | ||
khorne3 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| ``` | ||
|
|
||
| For a [SOCKS 5 proxy](https://en.wikipedia.org/wiki/SOCKS) with on port 1080, | ||
khorne3 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| use the setting: | ||
|
|
||
| ```yaml | ||
| coderd: | ||
| proxy: | ||
| http: socks5://10.10.10.10:1080 | ||
| ``` | ||
|
|
||
| If you specify a proxy for outbound HTTP connections and do not specify a proxy | ||
| for outgoing HTTPS connections, then Coder will proxy requests to HTTPS | ||
| endpoints using the HTTP proxy. The previous examples will proxy all requests, | ||
| regardless of protocol (HTTP or HTTPS), through the defined proxy. | ||
|
|
||
| To configure a different proxy to use for outbound HTTPS connections, you may | ||
| specify the same proxy types (`http`, `https`, `socks5`) using the | ||
| `coderd.proxy.https` key. | ||
jawnsy marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| For hosts that must connect directly, rather than using the proxy, define the | ||
| `exempt` setting with a comma-separated list of hosts and subdomains: | ||
khorne3 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| ```yaml | ||
| coderd: | ||
| proxy: | ||
| # Coder will establish connections to cluster.local or example.com, or | ||
| # their subdomains, directly, rather than using the proxy settings. | ||
| exempt: "cluster.local,example.com" | ||
| ``` | ||
|
|
||
| ## Reverse proxies | ||
|
|
||
| If you have a reverse proxy in front of Coder, as will be the case when you are | ||
| using an Ingress Controller, Coder will receive connections originating from the | ||
| proxy. In order for auditing, logging, and other features to associate the | ||
| connecting user's IP address information correctly, you will need to configure | ||
| the `coderd.reverseProxy` setting. | ||
|
|
||
| By default, to prevent clients from spoofing their originating IP addresses | ||
khorne3 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| using the `X-Forwarded-For` or similar headers, Coder will ignore all such | ||
| headers and remove them from proxied connections to | ||
| [Dev URL services](../../workspaces/devurls.md). | ||
|
|
||
| Specify a list of trusted origin addresses (those of the reverse proxy) in CIDR | ||
| format as follows: | ||
|
|
||
| ```yaml | ||
| coderd: | ||
| reverseProxy: | ||
| # These settings will treat inbound connections originating from | ||
| # localhost (127.0.0.1/8) and the RFC 1918 Class A network (10.0.0.0/8) | ||
| # as trusted proxies, and will consider the configured headers. | ||
| trustedOrigins: | ||
| - 127.0.0.1/8 | ||
| - 10.0.0.0/8 | ||
| headers: | ||
| - X-Forwarded-For | ||
| ``` | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.