Skip to content

Commit 158f4c2

Browse files
committed
more docs
1 parent e6354eb commit 158f4c2

File tree

2 files changed

+28
-18
lines changed

2 files changed

+28
-18
lines changed

README.md

Lines changed: 24 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,17 @@
11
# coder-hcloud
2-
*One-shot deployment and templates for Coder on Hetzner Cloud*
2+
*Terraform based one-shot deployment of [Coder OSS](https://github.com/coder/coder) on a [Hetzner Cloud](https://www.hetzner.com/de/cloud) instance.*
33

4-
This project serves two purposes:
5-
- Terraform based deployment of [Coder OSS](https://github.com/coder/coder) on a [Hetzner Cloud](https://www.hetzner.com/de/cloud) instance.
6-
- [Template](https://coder.com/docs/coder-oss/latest/templates)(s) for Coder to create [Workspaces](https://coder.com/docs/coder-oss/latest/workspaces) on Hetzner Cloud instances.
7-
8-
## Coder Deployment
9-
10-
### Quickstart
11-
- Copy `coder/config.auto.tfvars.example` to `coder/config.auto.tfvars`
12-
- Adjust `coder/config.auto.tfvars`
13-
- `cd coder && terraform init && terraform apply`
4+
## Quickstart
5+
- Copy `config.auto.tfvars.example` to `config.auto.tfvars`
6+
- Adjust `config.auto.tfvars`
7+
- `terraform init && terraform apply`
148
- Create DNS records
15-
- Open Coder, login with initial admin user
9+
- Open Coder, login with the initial admin user
10+
- (Install Templates from `coder-templates`)
1611

17-
### A little bit more details
12+
## A little bit more details
1813

19-
#### Configuration
14+
### Configuration/Variables
2015
| Variable | Default | Description |
2116
|---------------|---------|---------------------------------------------------------------------------------------------------------|
2217
| hcloud_apikey | | A R/W API-Key for the Hetzner Cloud project Coder shall be deployed in |
@@ -25,15 +20,27 @@ This project serves two purposes:
2520
| coder_domain | | Desired Domain for Coder (Used for CODER_ACCESS_URL, CODER_WILDCARD_ACCESS_URL and Caddy/Let's Encrypt) |
2621
| acme_email | | Administrative Email address used for Let's Encrypt and for the initial Coder user |
2722

28-
#### Resource allocation
23+
### Deployment
2924
*SSH*
3025

31-
Terraform creates TLS keys for the client and the host. The host key is installed later using cloud-init. The client key is registered in the Hetzner Cloud project and can be used later for regular maintenance tasks.
26+
Terraform creates keys for the client and the host. The host key is installed later using Cloud-init. The client key is registered in the Hetzner Cloud project and can be used later for regular maintenance tasks. You may use the preconfigured wrapper script `./bin/ssh` for easy access.
3227

3328
*Firewall*
3429

30+
A Hetzner Cloud Firewall is applied. Outgoing traffic is allowed generally. Incoming traffic is restricted to ICMP and HTTP 80, 443.
31+
32+
*Coder installation (Cloud-init)*
33+
34+
Coder is managed via Docker Compose (Adapted from https://github.com/coder/coder/blob/main/docker-compose.yaml).
35+
- First, only Coder and Postgress is started...
36+
- When Coder is ready, the initial admin account is created...
37+
- After that, the Proxy (Caddy) is started as well
38+
39+
*Maintenance*
40+
41+
While the Debian updates are mostly managed via `unattended-upgrades`, **you have to take care of the updates for the Docker Compose stack (`/root/coder/docker-compose.yaml`) manually!**
3542

3643

3744
## Templates
3845

39-
### [hcloud](templates/hcloud)
46+
### [hcloud](coder-templates/hcloud)

outputs.tf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
1-
output "instructions" {
1+
output "result" {
22
value = <<EOT
33
44
############
55
# required DNS-records
66
# ${var.coder_domain}. A ${hcloud_server.coder.ipv4_address}
77
# *.${var.coder_domain}. CNAME ${var.coder_domain}.
88
#
9+
# public url
10+
# https://${var.coder_domain}
11+
#
912
# initial user (admin)
1013
# ${var.acme_email}
1114
# ${random_string.coder_init_pass.result}

0 commit comments

Comments
 (0)