Skip to content

Commit fb5e0c4

Browse files
authored
docs: add TLS config steps for K8s (#9011)
* docs: add TLS config steps for K8s * add note on wildcard cert
1 parent 3245e91 commit fb5e0c4

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

docs/admin/configure.md

+30
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,36 @@ The Coder server can directly use TLS certificates with `CODER_TLS_ENABLE` and a
5555
- [Caddy](https://github.com/coder/coder/tree/main/examples/web-server/caddy)
5656
- [NGINX](https://github.com/coder/coder/tree/main/examples/web-server/nginx)
5757

58+
### Kubernetes TLS configuration
59+
60+
Below are the steps to configure Coder to terminate TLS when running on Kubernetes.
61+
You must have the certificate `.key` and `.crt` files in your working directory prior to step 1.
62+
63+
1. Create the TLS secret in your Kubernetes cluster
64+
65+
```console
66+
kubectl create secret tls coder-tls -n <coder-namespace> --key="tls.key" --cert="tls.crt"
67+
```
68+
69+
> You can use a single certificate for the both the access URL and wildcard access URL.
70+
> The certificate CN must match the wildcard domain, such as `*.example.coder.com`.
71+
72+
1. Reference the TLS secret in your Coder Helm chart values
73+
74+
```yaml
75+
coder:
76+
tls:
77+
secretName:
78+
- coder-tls
79+
80+
# Alternatively, if you use an Ingress controller to terminate TLS,
81+
# set the following values:
82+
ingress:
83+
enable: true
84+
secretName: coder-tls
85+
wildcardSecretName: coder-tls
86+
```
87+
5888
## PostgreSQL Database
5989
6090
Coder uses a PostgreSQL database to store users, workspace metadata, and other deployment information.

0 commit comments

Comments
 (0)