mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
chore(docs): reorganize installation docs (#11465)
This commit is contained in:
+11
-17
@@ -1,16 +1,6 @@
|
||||
You can install and run Coder using the official Docker images published on
|
||||
[GitHub Container Registry](https://github.com/coder/coder/pkgs/container/coder).
|
||||
|
||||
<blockquote class="warning">
|
||||
**Before you install**
|
||||
If you would like your workspaces to be able to run Docker, we recommend that you <a href="https://github.com/nestybox/sysbox#installation" target="_blank">install Sysbox</a> before proceeding.
|
||||
|
||||
As part of the Sysbox installation you will be required to remove all existing
|
||||
Docker containers including containers used by Coder workspaces. Installing
|
||||
Sysbox ahead of time will reduce disruption to your Coder instance.
|
||||
|
||||
</blockquote>
|
||||
|
||||
## Requirements
|
||||
|
||||
Docker is required. See the
|
||||
@@ -24,7 +14,7 @@ Docker is required. See the
|
||||
For proof-of-concept deployments, you can run a complete Coder instance with the
|
||||
following command.
|
||||
|
||||
```console
|
||||
```shell
|
||||
export CODER_DATA=$HOME/.config/coderv2-docker
|
||||
export DOCKER_GROUP=$(getent group docker | cut -d: -f3)
|
||||
mkdir -p $CODER_DATA
|
||||
@@ -43,13 +33,15 @@ systems `/var/run/docker.sock` is not group writeable or does not belong to the
|
||||
Coder configuration is defined via environment variables. Learn more about
|
||||
Coder's [configuration options](../admin/configure.md).
|
||||
|
||||
<div class="tabs">
|
||||
|
||||
## Run Coder with access URL and external PostgreSQL (recommended)
|
||||
|
||||
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.
|
||||
|
||||
```console
|
||||
```shell
|
||||
docker run --rm -it \
|
||||
-e CODER_ACCESS_URL="https://coder.example.com" \
|
||||
-e CODER_PG_CONNECTION_URL="postgresql://username:password@database/coder" \
|
||||
@@ -70,7 +62,7 @@ which includes an PostgreSQL container and volume.
|
||||
|
||||
2. Clone the `coder` repository:
|
||||
|
||||
```console
|
||||
```shell
|
||||
git clone https://github.com/coder/coder.git
|
||||
```
|
||||
|
||||
@@ -82,19 +74,19 @@ which includes an PostgreSQL container and volume.
|
||||
For proof-of-concept deployments, you can use
|
||||
[Coder's tunnel](../admin/configure.md#tunnel):
|
||||
|
||||
```console
|
||||
```shell
|
||||
cd coder
|
||||
|
||||
docker-compose up
|
||||
docker compose up
|
||||
```
|
||||
|
||||
For production deployments, we recommend setting an
|
||||
[access URL](../admin/configure.md#access-url):
|
||||
|
||||
```console
|
||||
```shell
|
||||
cd coder
|
||||
|
||||
CODER_ACCESS_URL=https://coder.example.com docker-compose up
|
||||
CODER_ACCESS_URL=https://coder.example.com docker compose up
|
||||
```
|
||||
|
||||
4. Visit the web ui via the configured url. You can add `/login` to the base url
|
||||
@@ -103,6 +95,8 @@ which includes an PostgreSQL container and volume.
|
||||
5. Follow the on-screen instructions log in and create your first template and
|
||||
workspace
|
||||
|
||||
</div>
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
### Docker-based workspace is stuck in "Connecting..."
|
||||
|
||||
Reference in New Issue
Block a user