mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
This reverts commit 61dcf643e8.
This commit is contained in:
@@ -4,7 +4,7 @@ Coder publishes self-contained .zip and .tar.gz archives in [GitHub releases](ht
|
||||
|
||||
1. Unzip the folder you just downloaded, and move the `coder` executable to a location that's on your `PATH`
|
||||
|
||||
```shell
|
||||
```console
|
||||
# ex. macOS and Linux
|
||||
mv coder /usr/local/bin
|
||||
```
|
||||
@@ -13,7 +13,7 @@ Coder publishes self-contained .zip and .tar.gz archives in [GitHub releases](ht
|
||||
|
||||
1. Start a Coder server
|
||||
|
||||
```shell
|
||||
```console
|
||||
# Automatically sets up an external access URL on *.try.coder.app
|
||||
coder server
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ CREATE DATABASE coder;
|
||||
Coder configuration is defined via [environment variables](../admin/configure.md).
|
||||
The database client requires the connection string provided via the `CODER_PG_CONNECTION_URL` variable.
|
||||
|
||||
```shell
|
||||
```console
|
||||
export CODER_PG_CONNECTION_URL="postgres://coder:secret42@localhost/coder?sslmode=disable"
|
||||
```
|
||||
|
||||
@@ -49,7 +49,7 @@ Once the schema is created, you can list all schemas with `\dn`:
|
||||
|
||||
In this case the database client requires the modified connection string:
|
||||
|
||||
```shell
|
||||
```console
|
||||
export CODER_PG_CONNECTION_URL="postgres://coder:secret42@localhost/coder?sslmode=disable&search_path=myschema"
|
||||
```
|
||||
|
||||
@@ -77,7 +77,7 @@ ALTER ROLE coder SET search_path = myschema;
|
||||
Please make sure that the schema selected in the connection string `...&search_path=myschema` exists
|
||||
and the role has granted permissions to access it. The schema should be present on this listing:
|
||||
|
||||
```shell
|
||||
```console
|
||||
psql -U coder -c '\dn'
|
||||
```
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ Docker is required. See the [official installation documentation](https://docs.d
|
||||
For proof-of-concept deployments, you can run a complete Coder instance with
|
||||
the following command:
|
||||
|
||||
```shell
|
||||
```console
|
||||
export CODER_DATA=$HOME/.config/coderv2-docker
|
||||
export DOCKER_GROUP=$(getent group docker | cut -d: -f3)
|
||||
mkdir -p $CODER_DATA
|
||||
@@ -34,7 +34,7 @@ For production deployments, we recommend using an external PostgreSQL database
|
||||
(version 13 or higher). Set `ACCESS_URL` to the external URL that users and
|
||||
workspaces will use to connect to Coder.
|
||||
|
||||
```shell
|
||||
```console
|
||||
docker run --rm -it \
|
||||
-e CODER_ACCESS_URL="https://coder.example.com" \
|
||||
-e CODER_PG_CONNECTION_URL="postgresql://username:password@database/coder" \
|
||||
@@ -54,7 +54,7 @@ an PostgreSQL container and volume.
|
||||
|
||||
2. Clone the `coder` repository:
|
||||
|
||||
```shell
|
||||
```console
|
||||
git clone https://github.com/coder/coder.git
|
||||
```
|
||||
|
||||
@@ -64,7 +64,7 @@ an PostgreSQL container and volume.
|
||||
|
||||
For proof-of-concept deployments, you can use [Coder's tunnel](../admin/configure.md#tunnel):
|
||||
|
||||
```shell
|
||||
```console
|
||||
cd coder
|
||||
|
||||
docker-compose up
|
||||
@@ -72,7 +72,7 @@ an PostgreSQL container and volume.
|
||||
|
||||
For production deployments, we recommend setting an [access URL](../admin/configure.md#access-url):
|
||||
|
||||
```shell
|
||||
```console
|
||||
cd coder
|
||||
|
||||
CODER_ACCESS_URL=https://coder.example.com docker-compose up
|
||||
|
||||
@@ -13,7 +13,7 @@ to log in and manage templates.
|
||||
|
||||
1. Create a namespace for Coder, such as `coder`:
|
||||
|
||||
```shell
|
||||
```console
|
||||
$ kubectl create namespace coder
|
||||
```
|
||||
|
||||
@@ -34,7 +34,7 @@ to log in and manage templates.
|
||||
[helpful guides](https://phoenixnap.com/kb/postgresql-kubernetes) on the
|
||||
internet that explain sensible configurations for this chart. Example:
|
||||
|
||||
```shell
|
||||
```console
|
||||
# Install PostgreSQL
|
||||
helm repo add bitnami https://charts.bitnami.com/bitnami
|
||||
helm install coder-db bitnami/postgresql \
|
||||
@@ -47,7 +47,7 @@ to log in and manage templates.
|
||||
|
||||
The cluster-internal DB URL for the above database is:
|
||||
|
||||
```shell
|
||||
```console
|
||||
postgres://coder:coder@coder-db-postgresql.coder.svc.cluster.local:5432/coder?sslmode=disable
|
||||
```
|
||||
|
||||
@@ -59,13 +59,13 @@ to log in and manage templates.
|
||||
|
||||
1. Add the Coder Helm repo:
|
||||
|
||||
```shell
|
||||
```console
|
||||
helm repo add coder-v2 https://helm.coder.com/v2
|
||||
```
|
||||
|
||||
1. Create a secret with the database URL:
|
||||
|
||||
```shell
|
||||
```console
|
||||
# Uses Bitnami PostgreSQL example. If you have another database,
|
||||
# change to the proper URL.
|
||||
kubectl create secret generic coder-db-url -n coder \
|
||||
@@ -114,7 +114,7 @@ to log in and manage templates.
|
||||
|
||||
1. Run the following command to install the chart in your cluster.
|
||||
|
||||
```shell
|
||||
```console
|
||||
helm install coder coder-v2/coder \
|
||||
--namespace coder \
|
||||
--values values.yaml
|
||||
@@ -137,7 +137,7 @@ to log in and manage templates.
|
||||
To upgrade Coder in the future or change values,
|
||||
you can run the following command:
|
||||
|
||||
```shell
|
||||
```console
|
||||
helm repo update
|
||||
helm upgrade coder coder-v2/coder \
|
||||
--namespace coder \
|
||||
|
||||
@@ -105,13 +105,13 @@ Follow our [docker-compose](./docker.md#run-coder-with-docker-compose) documenta
|
||||
|
||||
First, make a create an empty plugins directory:
|
||||
|
||||
```shell
|
||||
```console
|
||||
mkdir $HOME/plugins
|
||||
```
|
||||
|
||||
Next, add a volume mount to docker-compose.yaml:
|
||||
|
||||
```shell
|
||||
```console
|
||||
vim docker-compose.yaml
|
||||
```
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
1. Run Coder as a system service.
|
||||
|
||||
```shell
|
||||
```console
|
||||
# Optional) Set up an access URL
|
||||
sudo vim /etc/coder.d/coder.env
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
1. Visit the Coder URL in the logs to set up your first account, or use the CLI:
|
||||
|
||||
```shell
|
||||
```console
|
||||
coder login <access-url>
|
||||
```
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
After updating Coder or applying configuration changes, restart the server:
|
||||
|
||||
```shell
|
||||
```console
|
||||
sudo systemctl restart coder
|
||||
```
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ To uninstall your Coder server, delete the following directories.
|
||||
|
||||
## Cached Coder releases
|
||||
|
||||
```shell
|
||||
```console
|
||||
rm -rf ~/.cache/coder
|
||||
```
|
||||
|
||||
@@ -14,31 +14,31 @@ rm -rf ~/.cache/coder
|
||||
|
||||
Debian, Ubuntu:
|
||||
|
||||
```shell
|
||||
```console
|
||||
sudo apt remove coder
|
||||
```
|
||||
|
||||
Fedora, CentOS, RHEL, SUSE:
|
||||
|
||||
```shell
|
||||
```console
|
||||
sudo yum remove coder
|
||||
```
|
||||
|
||||
Alpine:
|
||||
|
||||
```shell
|
||||
```console
|
||||
sudo apk del coder
|
||||
```
|
||||
|
||||
If you installed Coder manually or used the install script on an unsupported operating system, you can remove the binary directly:
|
||||
|
||||
```shell
|
||||
```console
|
||||
sudo rm /usr/local/bin/coder
|
||||
```
|
||||
|
||||
## Coder as a system service configuration
|
||||
|
||||
```shell
|
||||
```console
|
||||
sudo rm /etc/coder.d/coder.env
|
||||
```
|
||||
|
||||
@@ -51,18 +51,18 @@ sudo rm /etc/coder.d/coder.env
|
||||
|
||||
### macOS
|
||||
|
||||
```shell
|
||||
```console
|
||||
rm -rf ~/Library/Application\ Support/coderv2
|
||||
```
|
||||
|
||||
### Linux
|
||||
|
||||
```shell
|
||||
```console
|
||||
rm -rf ~/.config/coderv2
|
||||
```
|
||||
|
||||
### Windows
|
||||
|
||||
```shell
|
||||
```console
|
||||
C:\Users\USER\AppData\Roaming\coderv2
|
||||
```
|
||||
|
||||
@@ -14,7 +14,7 @@ Use the Windows installer to download the CLI and add Coder to `PATH`. Alternati
|
||||
|
||||
3. Start a Coder server
|
||||
|
||||
```shell
|
||||
```console
|
||||
# Automatically sets up an external access URL on *.try.coder.app
|
||||
coder server
|
||||
|
||||
|
||||
Reference in New Issue
Block a user