Skip to content

Commit fa1215f

Browse files
committed
now workspaces
1 parent 894cddb commit fa1215f

File tree

4 files changed

+47
-14
lines changed

4 files changed

+47
-14
lines changed

docs/admin/architectures/1k-users.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,6 @@ tech startups, educational units, or small to mid-sized enterprises.
1212

1313
### Coderd nodes
1414

15-
| Users | Cluster capacity | Replicas | GCP | AWS | Azure |
15+
| Users | Node capacity | Replicas | GCP | AWS | Azure |
1616
| ----------- | ------------------- | -------- | --------------- | ---------- | ----------------- |
1717
| Up to 1,000 | 2 vCPU, 8 GB memory | 2 | `n1-standard-2` | `t3.large` | `Standard_D2s_v3` |

docs/admin/architectures/2k-users.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,6 @@ enabling it for deployment reliability.
1717

1818
### Coderd nodes
1919

20-
| Users | Cluster capacity | Replicas | GCP | AWS | Azure |
20+
| Users | Node capacity | Replicas | GCP | AWS | Azure |
2121
| ----------- | -------------------- | -------- | --------------- | ----------- | ----------------- |
2222
| Up to 2,000 | 4 vCPU, 16 GB memory | 2 | `n1-standard-4` | `t3.xlarge` | `Standard_D4s_v3` |

docs/admin/architectures/3k-users.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ purposes.
1313

1414
### Coderd nodes
1515

16-
| Users | Cluster capacity | Replicas | GCP | AWS | Azure |
16+
| Users | Node capacity | Replicas | GCP | AWS | Azure |
1717
| ----------- | -------------------- | -------- | --------------- | ----------- | ----------------- |
1818
| Up to 3,000 | 8 vCPU, 32 GB memory | 4 | `n1-standard-4` | `t3.xlarge` | `Standard_D4s_v3` |

docs/admin/architectures/index.md

+44-11
Original file line numberDiff line numberDiff line change
@@ -205,27 +205,60 @@ this option enabled unless there are compelling reasons to disable it.
205205

206206
Inactive users do not consume Coder resources.
207207

208-
#### HTTP API latency
208+
#### Scaling formula
209209

210-
API latency/response time average number of HTTP requests
210+
When determining scaling requirements, consider the following factors:
211211

212-
depending on database perf
212+
- 1 vCPU x 2 GB memory x 250 users: A reasonable formula to determine resource
213+
allocation based on the number of users and their expected usage patterns.
214+
- API latency/response time: Monitor API latency and response times to ensure
215+
optimal performance under varying loads.
216+
- Average number of HTTP requests: Track the average number of HTTP requests to
217+
gauge system usage and identify potential bottlenecks.
213218

214-
TODO
219+
**Node Autoscaling**
215220

216-
#### Scaling formula
221+
We recommend to disable autoscaling for `coderd` nodes. Autoscaling can cause
222+
interruptions for user connections, see [Autoscaling](../scale.md#autoscaling)
223+
for more details.
224+
225+
### Workspaces
217226

218-
reasonable ratio/formula: CPU x memory x users reasonable ratio/formula:
219-
provisionerd x users API latency/response time average number of HTTP requests
227+
Assumptions:
220228

221-
TODO
229+
workspaces also run on the same Kubernetes cluster (recommend a different
230+
namespace/node pool)
222231

223-
### Workspaces
232+
developers can pick between 4-8 CPU and 4-16 GB RAM workspaces (limits)
233+
234+
developers have a resource quota of 16 GPU 32 GB RAM (2-maxed out workspaces).
224235

225-
TODO
236+
However, the Coder agent itself requires at minimum 0.1 CPU cores and 256 MB to
237+
run inside a workspace.
238+
239+
web microservice development use case: resources are mostly underutilized but
240+
spike during builds
241+
242+
Case study:
243+
244+
Developers for up to 2000+ users architecture are in 2 regions (a different
245+
cluster) and are evenly split. In practice, this doesn’t change much besides the
246+
diagram and workspaces node pool autoscaling config as it still uses the central
247+
provisioner. Recommend multiple provisioner groups for zero-trust and
248+
multi-cloud use cases. Developers for up to 3000+ users architecture are also in
249+
an on-premises network. Document a provisioner running in a different cloud
250+
environment, and the zero-trust benefits of that.
251+
252+
scaling formula
253+
254+
provisionerd x users: Another formula to consider, focusing on the capacity of
255+
provisioner nodes relative to the number of workspace builds, triggered by
256+
users.
226257

227258
### Database
228259

229-
TODO
260+
PostgreSQL database
261+
262+
measure and document the impact of dbcrypt
230263

231264
###

0 commit comments

Comments
 (0)