This article walks you through the process of installing Coder onto your Kubernetes cluster.
Install the following dependencies if you haven't already:
For production deployments: set up and use an external PostgreSQL instance to store data, including workspace information and session tokens.
We recommend running Coder in a separate namespace; to do so, run
kubectl create namespace coder
Next, change the kubectl context to point to your newly created namespace:
kubectl config set-context --current --namespace=coder
Add the Coder Helm repo
helm repo add coder https://helm.coder.com
Install the Helm chart onto your cluster (see the
changelog for a list of Coder versions or run
helm search repo coder -l)
helm install coder coder/coder --namespace coder
Steps 3-5 are optional for non-production deployments.
Get a copy of your Helm chart so that you can modify it; you'll need to modify the Helm chart to update your PostgreSQL databases (step 4) and enable dev URLs (step 5):
a. Get a copy of your existing Helm chart and save it as
helm show values coder/coder > current-values.yaml
b. Edit the
current-values.yaml file as needed. Be sure to remove the lines
that you are not modifying, otherwise the contents of
will override those in the default chart.
c. Upgrade/install your Coder deployment with the updated Helm chart (be sure to replace the placeholder value with your Coder version). This must be done whenever you update the Helm chart:
helm upgrade coder coder/coder -n coder --version=<VERSION> --values current-values.yaml
If you omit
--version, you'll upgrade to the latest version, excluding release candidates (RCs). To include RCs, provide the
We do not provide documentation for RCs, and you should not use them unless you've been instructed to do so by Coder. You can identify RCs by the presence of
-rcin the version number (e.g.,
Ensure that you have superuser privileges to your PostgreSQL database. Add the following to your Helm chart so that Coder uses your external PostgreSQL databases:
postgres: useDefault: false host: HOST_ADDRESS port: PORT_NUMBER user: YOUR_USER_NAME database: YOUR_DATABASE passwordSecret: secret-name sslMode: require
To create the
kubectl create secret generic <NAME> --from-file=test=/dev/stdin
(be sure to replace
UserDefinedPassword with your actual password).
You can find/define these values in your PostgreSQL server configuration file.
For more information, see our guide on setting up a PostgreSQL instance.
Enable dev URL usage. Dev URLs allow users to access the web servers running in your workspace. To enable, provide a wildcard domain and its DNS certificate and update your Helm chart accordingly. This step is optional but recommended.
After you've created the pod, tail the logs to find the randomly generated password for the admin user
kubectl logs -n coder -l coder.deployment=cemanager -c cemanager \ --tail=-1 | grep -A1 -B2 Password
When this step is done, you will see:
---------------------- User: admin Password: kv...k3 ----------------------
These are the credentials you need to continue setup using Coder's web UI.
If you lose your admin credentials, you can use the admin password reset process to regain access.
At this time, we recommend review Coder's default logging settings. Logs are helpful for monitoring the health of your cluster and troubleshooting, and Coder offers you several options for obtaining these.
To access Coder's web UI, you'll need to get its IP address by running the following in the terminal to list the Kubernetes services running:
kubectl --namespace coder get services
The row for the ingress-nginx service includes an EXTERNAL-IP value; this is the IP address you need.
In your browser, navigate to the external IP of ingress-nginx.
Use the admin credentials you obtained in this installation guide's previous step to log in to the Coder platform. If this is the first time you've logged in, Coder will prompt you to change your password.
At this point, you're ready to proceed to configuring Coder.